2008-11-27 Øyvind Harboe <oyvind.harboe@zylin.com>
[nios2ecos.git] / docs / eCos for Nios II.htm
bloba6df397ac1857752ab1a151fd46218210116e164
1 <html xmlns:v="urn:schemas-microsoft-com:vml"
2 xmlns:o="urn:schemas-microsoft-com:office:office"
3 xmlns:w="urn:schemas-microsoft-com:office:word"
4 xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882"
5 xmlns="http://www.w3.org/TR/REC-html40">
7 <head>
8 <meta http-equiv=Content-Type content="text/html; charset=windows-1252">
9 <meta name=ProgId content=Word.Document>
10 <meta name=Generator content="Microsoft Word 11">
11 <meta name=Originator content="Microsoft Word 11">
12 <link rel=File-List href="filelist.xml">
13 <link rel=Edit-Time-Data href="editdata.mso">
14 <!--[if !mso]>
15 <style>
16 v\:* {behavior:url(#default#VML);}
17 o\:* {behavior:url(#default#VML);}
18 w\:* {behavior:url(#default#VML);}
19 .shape {behavior:url(#default#VML);}
20 </style>
21 <![endif]-->
22 <title>eCos 2.0 for Nios II</title>
23 <!--[if gte mso 9]><xml>
24 <o:CustomDocumentProperties>
25 <o:Version dt:dt="string">0.1</o:Version>
26 <o:System dt:dt="string">n/a</o:System>
27 <o:Subsystem dt:dt="string">n/a</o:Subsystem>
28 <o:Publisher dt:dt="string">n/a</o:Publisher>
29 </o:CustomDocumentProperties>
30 </xml><![endif]--><!--[if gte mso 9]><xml>
31 <w:WordDocument>
32 <w:DisplayHorizontalDrawingGridEvery>0</w:DisplayHorizontalDrawingGridEvery>
33 <w:DisplayVerticalDrawingGridEvery>0</w:DisplayVerticalDrawingGridEvery>
34 <w:UseMarginsForDrawingGridOrigin/>
35 <w:ValidateAgainstSchemas/>
36 <w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
37 <w:IgnoreMixedContent>false</w:IgnoreMixedContent>
38 <w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
39 <w:Compatibility>
40 <w:WW6BorderRules/>
41 <w:FootnoteLayoutLikeWW8/>
42 <w:ShapeLayoutLikeWW8/>
43 <w:AlignTablesRowByRow/>
44 <w:ForgetLastTabAlignment/>
45 <w:LayoutRawTableWidth/>
46 <w:LayoutTableRowsApart/>
47 <w:UseWord97LineBreakingRules/>
48 <w:UseFELayout/>
49 </w:Compatibility>
50 <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
51 </w:WordDocument>
52 </xml><![endif]--><!--[if gte mso 9]><xml>
53 <w:LatentStyles DefLockedState="false" LatentStyleCount="156">
54 </w:LatentStyles>
55 </xml><![endif]-->
56 <style>
57 <!--
58 /* Font Definitions */
59 @font-face
60 {font-family:"MS Mincho";
61 panose-1:2 2 6 9 4 2 5 8 3 4;
62 mso-font-alt:"\FF2D\FF33 \660E\671D";
63 mso-font-charset:128;
64 mso-generic-font-family:modern;
65 mso-font-pitch:fixed;
66 mso-font-signature:-1610612033 1757936891 16 0 131231 0;}
67 @font-face
68 {font-family:Tahoma;
69 panose-1:2 11 6 4 3 5 4 4 2 4;
70 mso-font-charset:0;
71 mso-generic-font-family:swiss;
72 mso-font-pitch:variable;
73 mso-font-signature:1627421319 -2147483648 8 0 66047 0;}
74 @font-face
75 {font-family:"\@MS Mincho";
76 panose-1:2 2 6 9 4 2 5 8 3 4;
77 mso-font-charset:128;
78 mso-generic-font-family:modern;
79 mso-font-pitch:fixed;
80 mso-font-signature:-1610612033 1757936891 16 0 131231 0;}
81 /* Style Definitions */
82 p.MsoNormal, li.MsoNormal, div.MsoNormal
83 {mso-style-parent:"";
84 margin-top:6.0pt;
85 margin-right:0in;
86 margin-bottom:0in;
87 margin-left:0in;
88 margin-bottom:.0001pt;
89 mso-pagination:widow-orphan;
90 font-size:10.0pt;
91 font-family:Arial;
92 mso-fareast-font-family:"Times New Roman";
93 mso-bidi-font-family:"Times New Roman";}
95 {mso-style-next:Normal;
96 margin-top:.5in;
97 margin-right:0in;
98 margin-bottom:3.0pt;
99 margin-left:0in;
100 text-indent:0in;
101 mso-pagination:widow-orphan;
102 page-break-after:avoid;
103 mso-outline-level:1;
104 mso-list:l6 level1 lfo1;
105 font-size:14.0pt;
106 mso-bidi-font-size:10.0pt;
107 font-family:Arial;
108 mso-bidi-font-family:"Times New Roman";
109 mso-font-kerning:14.0pt;
110 mso-bidi-font-weight:normal;}
112 {mso-style-next:Normal;
113 margin-top:24.0pt;
114 margin-right:0in;
115 margin-bottom:0in;
116 margin-left:0in;
117 margin-bottom:.0001pt;
118 text-indent:0in;
119 mso-pagination:widow-orphan lines-together;
120 page-break-after:avoid;
121 mso-outline-level:2;
122 mso-list:l6 level2 lfo1;
123 font-size:12.0pt;
124 mso-bidi-font-size:10.0pt;
125 font-family:Arial;
126 mso-bidi-font-family:"Times New Roman";
127 mso-bidi-font-weight:normal;}
129 {mso-style-next:Normal;
130 margin-top:.25in;
131 margin-right:0in;
132 margin-bottom:0in;
133 margin-left:0in;
134 margin-bottom:.0001pt;
135 text-indent:0in;
136 mso-pagination:widow-orphan lines-together;
137 page-break-after:avoid;
138 mso-outline-level:3;
139 mso-list:l6 level3 lfo1;
140 font-size:10.0pt;
141 font-family:Arial;
142 mso-bidi-font-family:"Times New Roman";
143 mso-bidi-font-weight:normal;}
145 {mso-style-next:Normal;
146 margin-top:12.0pt;
147 margin-right:0in;
148 margin-bottom:0in;
149 margin-left:0in;
150 margin-bottom:.0001pt;
151 text-indent:0in;
152 mso-pagination:widow-orphan lines-together;
153 page-break-after:avoid;
154 mso-outline-level:4;
155 mso-list:l6 level4 lfo1;
156 font-size:10.0pt;
157 font-family:Arial;
158 mso-bidi-font-family:"Times New Roman";
159 mso-bidi-font-weight:normal;}
161 {mso-style-next:Normal;
162 margin-top:12.0pt;
163 margin-right:0in;
164 margin-bottom:3.0pt;
165 margin-left:0in;
166 text-indent:0in;
167 mso-pagination:widow-orphan;
168 mso-outline-level:5;
169 mso-list:l6 level5 lfo1;
170 font-size:11.0pt;
171 mso-bidi-font-size:10.0pt;
172 font-family:Arial;
173 mso-bidi-font-family:"Times New Roman";
174 font-weight:normal;}
176 {mso-style-next:Normal;
177 margin-top:12.0pt;
178 margin-right:0in;
179 margin-bottom:3.0pt;
180 margin-left:0in;
181 text-indent:0in;
182 mso-pagination:widow-orphan;
183 mso-outline-level:6;
184 mso-list:l6 level6 lfo1;
185 font-size:11.0pt;
186 mso-bidi-font-size:10.0pt;
187 font-family:Arial;
188 mso-bidi-font-family:"Times New Roman";
189 font-weight:normal;
190 font-style:italic;
191 mso-bidi-font-style:normal;}
192 p.MsoHeading7, li.MsoHeading7, div.MsoHeading7
193 {mso-style-next:Normal;
194 margin-top:12.0pt;
195 margin-right:0in;
196 margin-bottom:3.0pt;
197 margin-left:0in;
198 text-indent:0in;
199 mso-pagination:widow-orphan;
200 mso-outline-level:7;
201 mso-list:l6 level7 lfo1;
202 font-size:10.0pt;
203 font-family:Arial;
204 mso-fareast-font-family:"Times New Roman";
205 mso-bidi-font-family:"Times New Roman";}
206 p.MsoHeading8, li.MsoHeading8, div.MsoHeading8
207 {mso-style-next:Normal;
208 margin-top:12.0pt;
209 margin-right:0in;
210 margin-bottom:3.0pt;
211 margin-left:0in;
212 text-indent:0in;
213 mso-pagination:widow-orphan;
214 mso-outline-level:8;
215 mso-list:l6 level8 lfo1;
216 font-size:10.0pt;
217 font-family:Arial;
218 mso-fareast-font-family:"Times New Roman";
219 mso-bidi-font-family:"Times New Roman";
220 font-style:italic;
221 mso-bidi-font-style:normal;}
222 p.MsoHeading9, li.MsoHeading9, div.MsoHeading9
223 {mso-style-name:"Heading 9\,Appendix";
224 mso-style-next:Normal;
225 margin-top:0in;
226 margin-right:0in;
227 margin-bottom:3.0pt;
228 margin-left:0in;
229 text-indent:0in;
230 page-break-before:always;
231 mso-pagination:widow-orphan lines-together;
232 page-break-after:avoid;
233 mso-outline-level:9;
234 mso-list:l6 level9 lfo1;
235 font-size:14.0pt;
236 mso-bidi-font-size:10.0pt;
237 font-family:Arial;
238 mso-fareast-font-family:"Times New Roman";
239 mso-bidi-font-family:"Times New Roman";
240 mso-font-kerning:14.0pt;
241 font-weight:bold;
242 mso-bidi-font-weight:normal;}
243 p.MsoToc1, li.MsoToc1, div.MsoToc1
244 {mso-style-noshow:yes;
245 mso-style-next:Normal;
246 margin-top:6.0pt;
247 margin-right:0in;
248 margin-bottom:6.0pt;
249 margin-left:0in;
250 mso-pagination:widow-orphan;
251 tab-stops:right dotted 6.0in;
252 font-size:10.0pt;
253 font-family:Arial;
254 mso-fareast-font-family:"Times New Roman";
255 mso-bidi-font-family:"Times New Roman";
256 text-transform:uppercase;
257 font-weight:bold;
258 mso-bidi-font-weight:normal;}
259 p.MsoToc2, li.MsoToc2, div.MsoToc2
260 {mso-style-update:auto;
261 mso-style-noshow:yes;
262 mso-style-next:Normal;
263 margin-top:6.0pt;
264 margin-right:0in;
265 margin-bottom:0in;
266 margin-left:10.0pt;
267 margin-bottom:.0001pt;
268 mso-pagination:widow-orphan;
269 font-size:10.0pt;
270 font-family:Arial;
271 mso-fareast-font-family:"Times New Roman";
272 mso-bidi-font-family:"Times New Roman";}
273 p.MsoToc3, li.MsoToc3, div.MsoToc3
274 {mso-style-update:auto;
275 mso-style-noshow:yes;
276 mso-style-next:Normal;
277 margin-top:6.0pt;
278 margin-right:0in;
279 margin-bottom:0in;
280 margin-left:20.0pt;
281 margin-bottom:.0001pt;
282 mso-pagination:widow-orphan;
283 font-size:10.0pt;
284 font-family:Arial;
285 mso-fareast-font-family:"Times New Roman";
286 mso-bidi-font-family:"Times New Roman";}
287 p.MsoToc4, li.MsoToc4, div.MsoToc4
288 {mso-style-update:auto;
289 mso-style-noshow:yes;
290 mso-style-next:Normal;
291 margin-top:6.0pt;
292 margin-right:0in;
293 margin-bottom:0in;
294 margin-left:30.0pt;
295 margin-bottom:.0001pt;
296 mso-pagination:widow-orphan;
297 font-size:10.0pt;
298 font-family:Arial;
299 mso-fareast-font-family:"Times New Roman";
300 mso-bidi-font-family:"Times New Roman";}
301 p.MsoToc9, li.MsoToc9, div.MsoToc9
302 {mso-style-noshow:yes;
303 mso-style-next:Normal;
304 margin-top:6.0pt;
305 margin-right:0in;
306 margin-bottom:0in;
307 margin-left:0in;
308 margin-bottom:.0001pt;
309 mso-pagination:widow-orphan;
310 tab-stops:right dotted 6.0in;
311 font-size:10.0pt;
312 font-family:Arial;
313 mso-fareast-font-family:"Times New Roman";
314 mso-bidi-font-family:"Times New Roman";
315 text-transform:uppercase;
316 font-weight:bold;
317 mso-bidi-font-weight:normal;}
318 p.MsoFootnoteText, li.MsoFootnoteText, div.MsoFootnoteText
319 {mso-style-noshow:yes;
320 margin-top:6.0pt;
321 margin-right:0in;
322 margin-bottom:0in;
323 margin-left:0in;
324 margin-bottom:.0001pt;
325 mso-pagination:widow-orphan;
326 font-size:10.0pt;
327 font-family:Arial;
328 mso-fareast-font-family:"Times New Roman";
329 mso-bidi-font-family:"Times New Roman";}
330 p.MsoCommentText, li.MsoCommentText, div.MsoCommentText
331 {mso-style-noshow:yes;
332 margin-top:6.0pt;
333 margin-right:0in;
334 margin-bottom:0in;
335 margin-left:0in;
336 margin-bottom:.0001pt;
337 mso-pagination:widow-orphan;
338 font-size:10.0pt;
339 font-family:Arial;
340 mso-fareast-font-family:"Times New Roman";
341 mso-bidi-font-family:"Times New Roman";}
342 p.MsoHeader, li.MsoHeader, div.MsoHeader
343 {margin-top:6.0pt;
344 margin-right:0in;
345 margin-bottom:0in;
346 margin-left:0in;
347 margin-bottom:.0001pt;
348 mso-pagination:widow-orphan;
349 tab-stops:center 3.0in right 6.0in;
350 font-size:10.0pt;
351 font-family:Arial;
352 mso-fareast-font-family:"Times New Roman";
353 mso-bidi-font-family:"Times New Roman";}
354 p.MsoFooter, li.MsoFooter, div.MsoFooter
355 {margin-top:6.0pt;
356 margin-right:0in;
357 margin-bottom:0in;
358 margin-left:0in;
359 margin-bottom:.0001pt;
360 mso-pagination:widow-orphan;
361 tab-stops:center 3.0in right 6.0in;
362 font-size:10.0pt;
363 font-family:Arial;
364 mso-fareast-font-family:"Times New Roman";
365 mso-bidi-font-family:"Times New Roman";}
366 p.MsoCaption, li.MsoCaption, div.MsoCaption
367 {mso-style-noshow:yes;
368 mso-style-next:Normal;
369 margin-top:6.0pt;
370 margin-right:0in;
371 margin-bottom:6.0pt;
372 margin-left:0in;
373 mso-pagination:widow-orphan;
374 font-size:10.0pt;
375 font-family:Arial;
376 mso-fareast-font-family:"Times New Roman";
377 mso-bidi-font-family:"Times New Roman";
378 font-weight:bold;}
379 span.MsoFootnoteReference
380 {mso-style-noshow:yes;
381 vertical-align:super;}
382 span.MsoCommentReference
383 {mso-style-noshow:yes;
384 mso-ansi-font-size:8.0pt;
385 mso-bidi-font-size:8.0pt;}
386 p.MsoDate, li.MsoDate, div.MsoDate
387 {mso-style-next:Normal;
388 margin-top:6.0pt;
389 margin-right:0in;
390 margin-bottom:0in;
391 margin-left:0in;
392 margin-bottom:.0001pt;
393 mso-pagination:widow-orphan;
394 font-size:10.0pt;
395 font-family:Arial;
396 mso-fareast-font-family:"Times New Roman";
397 mso-bidi-font-family:"Times New Roman";}
398 a:link, span.MsoHyperlink
399 {color:blue;
400 text-decoration:underline;
401 text-underline:single;}
402 a:visited, span.MsoHyperlinkFollowed
403 {color:purple;
404 text-decoration:underline;
405 text-underline:single;}
406 p.MsoDocumentMap, li.MsoDocumentMap, div.MsoDocumentMap
407 {mso-style-noshow:yes;
408 margin-top:6.0pt;
409 margin-right:0in;
410 margin-bottom:0in;
411 margin-left:0in;
412 margin-bottom:.0001pt;
413 mso-pagination:widow-orphan;
414 background:navy;
415 font-size:10.0pt;
416 font-family:Tahoma;
417 mso-fareast-font-family:"Times New Roman";}
418 code
419 {font-family:"Courier New";
420 mso-ascii-font-family:"Courier New";
421 mso-fareast-font-family:"Times New Roman";
422 mso-hansi-font-family:"Courier New";
423 mso-bidi-font-family:"Courier New";}
425 {margin:0in;
426 margin-bottom:.0001pt;
427 mso-pagination:widow-orphan;
428 font-size:10.0pt;
429 font-family:"Courier New";
430 mso-fareast-font-family:"Times New Roman";
431 color:black;}
433 {font-family:"Courier New";
434 mso-ascii-font-family:"Courier New";
435 mso-fareast-font-family:"Times New Roman";
436 mso-hansi-font-family:"Courier New";
437 mso-bidi-font-family:"Courier New";}
438 p.MsoCommentSubject, li.MsoCommentSubject, div.MsoCommentSubject
439 {mso-style-noshow:yes;
440 mso-style-parent:"Comment Text";
441 mso-style-next:"Comment Text";
442 margin-top:6.0pt;
443 margin-right:0in;
444 margin-bottom:0in;
445 margin-left:0in;
446 margin-bottom:.0001pt;
447 mso-pagination:widow-orphan;
448 font-size:10.0pt;
449 font-family:Arial;
450 mso-fareast-font-family:"Times New Roman";
451 mso-bidi-font-family:"Times New Roman";
452 font-weight:bold;}
453 p.MinorBullet, li.MinorBullet, div.MinorBullet
454 {mso-style-name:"Minor Bullet";
455 margin-top:6.0pt;
456 margin-right:0in;
457 margin-bottom:0in;
458 margin-left:.5in;
459 margin-bottom:.0001pt;
460 text-indent:-.25in;
461 mso-pagination:widow-orphan;
462 mso-list:l1 level1 lfo2;
463 tab-stops:list .5in;
464 font-size:10.0pt;
465 font-family:Arial;
466 mso-fareast-font-family:"Times New Roman";
467 mso-bidi-font-family:"Times New Roman";}
468 span.TreeCharCharCharCharCharCharCharCharCharCharCharCharCharChar
469 {mso-style-name:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char Char";
470 mso-style-locked:yes;
471 mso-style-link:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char";
472 mso-ansi-font-size:9.0pt;
473 mso-bidi-font-size:9.0pt;
474 font-family:"Courier New";
475 mso-ascii-font-family:"Courier New";
476 mso-hansi-font-family:"Courier New";
477 mso-bidi-font-family:"Courier New";
478 mso-ansi-language:EN-US;
479 mso-fareast-language:EN-US;
480 mso-bidi-language:AR-SA;
481 mso-bidi-font-weight:bold;}
482 p.TreeCharCharCharCharCharCharCharCharCharCharCharCharChar, li.TreeCharCharCharCharCharCharCharCharCharCharCharCharChar, div.TreeCharCharCharCharCharCharCharCharCharCharCharCharChar
483 {mso-style-name:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char";
484 mso-style-update:auto;
485 mso-style-parent:"";
486 mso-style-link:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char Char";
487 margin:0in;
488 margin-bottom:.0001pt;
489 mso-pagination:widow-orphan;
490 tab-stops:.2in .4in .6in .8in;
491 font-size:9.0pt;
492 font-family:"Courier New";
493 mso-fareast-font-family:"Times New Roman";
494 mso-bidi-font-family:"Times New Roman";
495 mso-bidi-font-weight:bold;}
496 p.TBD, li.TBD, div.TBD
497 {mso-style-name:TBD;
498 mso-style-next:Normal;
499 margin-top:6.0pt;
500 margin-right:0in;
501 margin-bottom:0in;
502 margin-left:0in;
503 margin-bottom:.0001pt;
504 mso-pagination:widow-orphan;
505 font-size:10.0pt;
506 font-family:Arial;
507 mso-fareast-font-family:"Times New Roman";
508 mso-bidi-font-family:"Times New Roman";
509 font-weight:bold;
510 mso-bidi-font-weight:normal;
511 font-style:italic;
512 mso-bidi-font-style:normal;}
513 span.StyleSnippetBoldCharCharCharChar
514 {mso-style-name:"Style Snippet + Bold Char Char Char Char";
515 mso-style-locked:yes;
516 mso-style-parent:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char Char";
517 mso-style-link:"Style Snippet + Bold Char Char Char";
518 mso-ansi-font-size:9.0pt;
519 mso-bidi-font-size:9.0pt;
520 font-family:"Courier New";
521 mso-ascii-font-family:"Courier New";
522 mso-hansi-font-family:"Courier New";
523 mso-bidi-font-family:"Courier New";
524 mso-ansi-language:EN-US;
525 mso-fareast-language:EN-US;
526 mso-bidi-language:AR-SA;
527 font-weight:bold;}
528 p.StyleSnippetBoldCharCharChar, li.StyleSnippetBoldCharCharChar, div.StyleSnippetBoldCharCharChar
529 {mso-style-name:"Style Snippet + Bold Char Char Char";
530 mso-style-parent:"Tree Char Char Char Char Char Char Char Char Char Char Char Char Char";
531 mso-style-link:"Style Snippet + Bold Char Char Char Char";
532 margin:0in;
533 margin-bottom:.0001pt;
534 mso-pagination:widow-orphan;
535 tab-stops:.2in .4in .6in .8in;
536 font-size:9.0pt;
537 font-family:"Courier New";
538 mso-fareast-font-family:"Times New Roman";
539 mso-bidi-font-family:"Times New Roman";
540 font-weight:bold;
541 mso-bidi-font-weight:normal;}
542 p.TreeCharCharCharCharCharChar, li.TreeCharCharCharCharCharChar, div.TreeCharCharCharCharCharChar
543 {mso-style-name:"Tree Char Char Char Char Char Char";
544 mso-style-update:auto;
545 mso-style-parent:"";
546 margin:0in;
547 margin-bottom:.0001pt;
548 mso-pagination:widow-orphan;
549 tab-stops:.2in .4in .6in .8in;
550 font-size:9.0pt;
551 font-family:"Courier New";
552 mso-fareast-font-family:"Times New Roman";
553 mso-bidi-font-family:"Times New Roman";
554 mso-bidi-font-weight:bold;}
555 /* Page Definitions */
556 @page
557 {mso-footnote-separator:url("header.htm") fs;
558 mso-footnote-continuation-separator:url("header.htm") fcs;
559 mso-endnote-separator:url("header.htm") es;
560 mso-endnote-continuation-separator:url("header.htm") ecs;}
561 @page Section1
562 {size:8.5in 11.0in;
563 margin:1.0in 1.25in 1.0in 1.25in;
564 mso-header-margin:.5in;
565 mso-footer-margin:.5in;
566 mso-page-numbers:1;
567 mso-header:url("header.htm") h1;
568 mso-footer:url("header.htm") f1;
569 mso-paper-source:0;}
570 div.Section1
571 {page:Section1;}
572 /* List Definitions */
573 @list l0
574 {mso-list-id:150870201;
575 mso-list-type:hybrid;
576 mso-list-template-ids:1295176160 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
577 @list l0:level1
578 {mso-level-number-format:bullet;
579 mso-level-text:\F0B7;
580 mso-level-tab-stop:.5in;
581 mso-level-number-position:left;
582 text-indent:-.25in;
583 font-family:Symbol;}
584 @list l0:level2
585 {mso-level-tab-stop:1.0in;
586 mso-level-number-position:left;
587 text-indent:-.25in;}
588 @list l0:level3
589 {mso-level-tab-stop:1.5in;
590 mso-level-number-position:left;
591 text-indent:-.25in;}
592 @list l0:level4
593 {mso-level-tab-stop:2.0in;
594 mso-level-number-position:left;
595 text-indent:-.25in;}
596 @list l0:level5
597 {mso-level-tab-stop:2.5in;
598 mso-level-number-position:left;
599 text-indent:-.25in;}
600 @list l0:level6
601 {mso-level-tab-stop:3.0in;
602 mso-level-number-position:left;
603 text-indent:-.25in;}
604 @list l0:level7
605 {mso-level-tab-stop:3.5in;
606 mso-level-number-position:left;
607 text-indent:-.25in;}
608 @list l0:level8
609 {mso-level-tab-stop:4.0in;
610 mso-level-number-position:left;
611 text-indent:-.25in;}
612 @list l0:level9
613 {mso-level-tab-stop:4.5in;
614 mso-level-number-position:left;
615 text-indent:-.25in;}
616 @list l1
617 {mso-list-id:950553735;
618 mso-list-type:hybrid;
619 mso-list-template-ids:954136038 1509342918 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
620 @list l1:level1
621 {mso-level-number-format:bullet;
622 mso-level-style-link:"Minor Bullet";
623 mso-level-text:o;
624 mso-level-tab-stop:.5in;
625 mso-level-number-position:left;
626 text-indent:-.25in;
627 font-family:"Courier New";
628 mso-bidi-font-family:"Times New Roman";}
629 @list l1:level2
630 {mso-level-tab-stop:1.0in;
631 mso-level-number-position:left;
632 text-indent:-.25in;}
633 @list l1:level3
634 {mso-level-tab-stop:1.5in;
635 mso-level-number-position:left;
636 text-indent:-.25in;}
637 @list l1:level4
638 {mso-level-tab-stop:2.0in;
639 mso-level-number-position:left;
640 text-indent:-.25in;}
641 @list l1:level5
642 {mso-level-tab-stop:2.5in;
643 mso-level-number-position:left;
644 text-indent:-.25in;}
645 @list l1:level6
646 {mso-level-tab-stop:3.0in;
647 mso-level-number-position:left;
648 text-indent:-.25in;}
649 @list l1:level7
650 {mso-level-tab-stop:3.5in;
651 mso-level-number-position:left;
652 text-indent:-.25in;}
653 @list l1:level8
654 {mso-level-tab-stop:4.0in;
655 mso-level-number-position:left;
656 text-indent:-.25in;}
657 @list l1:level9
658 {mso-level-tab-stop:4.5in;
659 mso-level-number-position:left;
660 text-indent:-.25in;}
661 @list l2
662 {mso-list-id:1048650778;
663 mso-list-type:hybrid;
664 mso-list-template-ids:2145013828 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
665 @list l2:level1
666 {mso-level-number-format:bullet;
667 mso-level-text:\F0B7;
668 mso-level-tab-stop:.5in;
669 mso-level-number-position:left;
670 text-indent:-.25in;
671 font-family:Symbol;}
672 @list l2:level2
673 {mso-level-tab-stop:1.0in;
674 mso-level-number-position:left;
675 text-indent:-.25in;}
676 @list l2:level3
677 {mso-level-tab-stop:1.5in;
678 mso-level-number-position:left;
679 text-indent:-.25in;}
680 @list l2:level4
681 {mso-level-tab-stop:2.0in;
682 mso-level-number-position:left;
683 text-indent:-.25in;}
684 @list l2:level5
685 {mso-level-tab-stop:2.5in;
686 mso-level-number-position:left;
687 text-indent:-.25in;}
688 @list l2:level6
689 {mso-level-tab-stop:3.0in;
690 mso-level-number-position:left;
691 text-indent:-.25in;}
692 @list l2:level7
693 {mso-level-tab-stop:3.5in;
694 mso-level-number-position:left;
695 text-indent:-.25in;}
696 @list l2:level8
697 {mso-level-tab-stop:4.0in;
698 mso-level-number-position:left;
699 text-indent:-.25in;}
700 @list l2:level9
701 {mso-level-tab-stop:4.5in;
702 mso-level-number-position:left;
703 text-indent:-.25in;}
704 @list l3
705 {mso-list-id:1306161181;
706 mso-list-type:hybrid;
707 mso-list-template-ids:-1162834752 134807553 134807555 134807557 134807553 134807555 134807557 134807553 134807555 134807557;}
708 @list l3:level1
709 {mso-level-number-format:bullet;
710 mso-level-text:\F0B7;
711 mso-level-tab-stop:.5in;
712 mso-level-number-position:left;
713 text-indent:-.25in;
714 font-family:Symbol;}
715 @list l3:level2
716 {mso-level-number-format:bullet;
717 mso-level-text:o;
718 mso-level-tab-stop:1.0in;
719 mso-level-number-position:left;
720 text-indent:-.25in;
721 font-family:"Courier New";}
722 @list l3:level3
723 {mso-level-tab-stop:1.5in;
724 mso-level-number-position:left;
725 text-indent:-.25in;}
726 @list l3:level4
727 {mso-level-tab-stop:2.0in;
728 mso-level-number-position:left;
729 text-indent:-.25in;}
730 @list l3:level5
731 {mso-level-tab-stop:2.5in;
732 mso-level-number-position:left;
733 text-indent:-.25in;}
734 @list l3:level6
735 {mso-level-tab-stop:3.0in;
736 mso-level-number-position:left;
737 text-indent:-.25in;}
738 @list l3:level7
739 {mso-level-tab-stop:3.5in;
740 mso-level-number-position:left;
741 text-indent:-.25in;}
742 @list l3:level8
743 {mso-level-tab-stop:4.0in;
744 mso-level-number-position:left;
745 text-indent:-.25in;}
746 @list l3:level9
747 {mso-level-tab-stop:4.5in;
748 mso-level-number-position:left;
749 text-indent:-.25in;}
750 @list l4
751 {mso-list-id:2030790487;
752 mso-list-type:hybrid;
753 mso-list-template-ids:-1778997684 67698703 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
754 @list l4:level1
755 {mso-level-tab-stop:52.8pt;
756 mso-level-number-position:left;
757 margin-left:52.8pt;
758 text-indent:-.25in;}
759 @list l4:level2
760 {mso-level-tab-stop:1.0in;
761 mso-level-number-position:left;
762 text-indent:-.25in;}
763 @list l4:level3
764 {mso-level-tab-stop:1.5in;
765 mso-level-number-position:left;
766 text-indent:-.25in;}
767 @list l4:level4
768 {mso-level-tab-stop:2.0in;
769 mso-level-number-position:left;
770 text-indent:-.25in;}
771 @list l4:level5
772 {mso-level-tab-stop:2.5in;
773 mso-level-number-position:left;
774 text-indent:-.25in;}
775 @list l4:level6
776 {mso-level-tab-stop:3.0in;
777 mso-level-number-position:left;
778 text-indent:-.25in;}
779 @list l4:level7
780 {mso-level-tab-stop:3.5in;
781 mso-level-number-position:left;
782 text-indent:-.25in;}
783 @list l4:level8
784 {mso-level-tab-stop:4.0in;
785 mso-level-number-position:left;
786 text-indent:-.25in;}
787 @list l4:level9
788 {mso-level-tab-stop:4.5in;
789 mso-level-number-position:left;
790 text-indent:-.25in;}
791 @list l5
792 {mso-list-id:2069188705;
793 mso-list-type:hybrid;
794 mso-list-template-ids:-1136239424 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
795 @list l5:level1
796 {mso-level-number-format:bullet;
797 mso-level-text:\F0B7;
798 mso-level-tab-stop:.5in;
799 mso-level-number-position:left;
800 text-indent:-.25in;
801 font-family:Symbol;}
802 @list l5:level2
803 {mso-level-tab-stop:1.0in;
804 mso-level-number-position:left;
805 text-indent:-.25in;}
806 @list l5:level3
807 {mso-level-tab-stop:1.5in;
808 mso-level-number-position:left;
809 text-indent:-.25in;}
810 @list l5:level4
811 {mso-level-tab-stop:2.0in;
812 mso-level-number-position:left;
813 text-indent:-.25in;}
814 @list l5:level5
815 {mso-level-tab-stop:2.5in;
816 mso-level-number-position:left;
817 text-indent:-.25in;}
818 @list l5:level6
819 {mso-level-tab-stop:3.0in;
820 mso-level-number-position:left;
821 text-indent:-.25in;}
822 @list l5:level7
823 {mso-level-tab-stop:3.5in;
824 mso-level-number-position:left;
825 text-indent:-.25in;}
826 @list l5:level8
827 {mso-level-tab-stop:4.0in;
828 mso-level-number-position:left;
829 text-indent:-.25in;}
830 @list l5:level9
831 {mso-level-tab-stop:4.5in;
832 mso-level-number-position:left;
833 text-indent:-.25in;}
834 @list l6
835 {mso-list-id:2114322569;
836 mso-list-template-ids:-1;}
837 @list l6:level1
838 {mso-level-style-link:"Heading 1";
839 mso-level-tab-stop:none;
840 mso-level-number-position:left;
841 mso-level-legacy:yes;
842 mso-level-legacy-indent:0in;
843 mso-level-legacy-space:.1in;
844 margin-left:0in;
845 text-indent:0in;}
846 @list l6:level2
847 {mso-level-style-link:"Heading 2";
848 mso-level-text:"%1\.%2";
849 mso-level-tab-stop:none;
850 mso-level-number-position:left;
851 mso-level-legacy:yes;
852 mso-level-legacy-indent:0in;
853 mso-level-legacy-space:.1in;
854 margin-left:0in;
855 text-indent:0in;}
856 @list l6:level3
857 {mso-level-style-link:"Heading 3";
858 mso-level-text:"%1\.%2\.%3";
859 mso-level-tab-stop:none;
860 mso-level-number-position:left;
861 mso-level-legacy:yes;
862 mso-level-legacy-indent:0in;
863 mso-level-legacy-space:.1in;
864 margin-left:0in;
865 text-indent:0in;}
866 @list l6:level4
867 {mso-level-style-link:"Heading 4";
868 mso-level-text:"%1\.%2\.%3\.%4";
869 mso-level-tab-stop:none;
870 mso-level-number-position:left;
871 mso-level-legacy:yes;
872 mso-level-legacy-indent:0in;
873 mso-level-legacy-space:.1in;
874 margin-left:0in;
875 text-indent:0in;}
876 @list l6:level5
877 {mso-level-style-link:"Heading 5";
878 mso-level-text:"%1\.%2\.%3\.%4\.%5";
879 mso-level-tab-stop:none;
880 mso-level-number-position:left;
881 mso-level-legacy:yes;
882 mso-level-legacy-indent:0in;
883 mso-level-legacy-space:.1in;
884 margin-left:0in;
885 text-indent:0in;}
886 @list l6:level6
887 {mso-level-style-link:"Heading 6";
888 mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6";
889 mso-level-tab-stop:none;
890 mso-level-number-position:left;
891 mso-level-legacy:yes;
892 mso-level-legacy-indent:0in;
893 mso-level-legacy-space:.1in;
894 margin-left:0in;
895 text-indent:0in;}
896 @list l6:level7
897 {mso-level-style-link:"Heading 7";
898 mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6\.%7";
899 mso-level-tab-stop:none;
900 mso-level-number-position:left;
901 mso-level-legacy:yes;
902 mso-level-legacy-indent:0in;
903 mso-level-legacy-space:.1in;
904 margin-left:0in;
905 text-indent:0in;}
906 @list l6:level8
907 {mso-level-style-link:"Heading 8";
908 mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6\.%7\.%8";
909 mso-level-tab-stop:none;
910 mso-level-number-position:left;
911 mso-level-legacy:yes;
912 mso-level-legacy-indent:0in;
913 mso-level-legacy-space:.1in;
914 margin-left:0in;
915 text-indent:0in;}
916 @list l6:level9
917 {mso-level-number-format:alpha-upper;
918 mso-level-style-link:"Heading 9";
919 mso-level-text:"Appendix %9\:";
920 mso-level-tab-stop:none;
921 mso-level-number-position:left;
922 mso-level-legacy:yes;
923 mso-level-legacy-indent:0in;
924 mso-level-legacy-space:.1in;
925 margin-left:0in;
926 text-indent:0in;}
928 {margin-bottom:0in;}
930 {margin-bottom:0in;}
932 </style>
933 <!--[if gte mso 10]>
934 <style>
935 /* Style Definitions */
936 table.MsoNormalTable
937 {mso-style-name:"Table Normal";
938 mso-tstyle-rowband-size:0;
939 mso-tstyle-colband-size:0;
940 mso-style-noshow:yes;
941 mso-style-parent:"";
942 mso-padding-alt:0in 5.4pt 0in 5.4pt;
943 mso-para-margin:0in;
944 mso-para-margin-bottom:.0001pt;
945 mso-pagination:widow-orphan;
946 font-size:10.0pt;
947 font-family:"Times New Roman";
948 mso-fareast-font-family:"Times New Roman";
949 mso-ansi-language:#0400;
950 mso-fareast-language:#0400;
951 mso-bidi-language:#0400;}
952 table.MsoTableGrid
953 {mso-style-name:"Table Grid";
954 mso-tstyle-rowband-size:0;
955 mso-tstyle-colband-size:0;
956 border:solid windowtext 1.0pt;
957 mso-border-alt:solid windowtext .5pt;
958 mso-padding-alt:0in 5.4pt 0in 5.4pt;
959 mso-border-insideh:.5pt solid windowtext;
960 mso-border-insidev:.5pt solid windowtext;
961 mso-para-margin-top:6.0pt;
962 mso-para-margin-right:0in;
963 mso-para-margin-bottom:0in;
964 mso-para-margin-left:0in;
965 mso-para-margin-bottom:.0001pt;
966 mso-pagination:widow-orphan;
967 font-size:10.0pt;
968 font-family:"Times New Roman";
969 mso-ansi-language:#0400;
970 mso-fareast-language:#0400;
971 mso-bidi-language:#0400;}
972 </style>
973 <![endif]--><!--[if gte mso 9]><xml>
974 <o:shapedefaults v:ext="edit" spidmax="51202" fill="f" fillcolor="#396">
975 <v:fill color="#396" on="f"/>
976 <o:colormenu v:ext="edit" fillcolor="none"/>
977 </o:shapedefaults></xml><![endif]--><!--[if gte mso 9]><xml>
978 <o:shapelayout v:ext="edit">
979 <o:idmap v:ext="edit" data="1"/>
980 </o:shapelayout></xml><![endif]-->
981 </head>
983 <body lang=EN-US link=blue vlink=purple style='tab-interval:.5in'>
985 <div class=Section1>
987 <p class=MsoNormal align=center style='text-align:center'><span
988 style='font-size:35.0pt;text-transform:uppercase'>eCos for Nios II</span><span
989 style='font-size:35.0pt;mso-bidi-font-size:10.0pt'><o:p></o:p></span></p>
991 <p class=MsoNormal align=center style='text-align:center'><span
992 style='font-size:20.0pt;mso-bidi-font-size:10.0pt'><o:p>&nbsp;</o:p></span></p>
994 <p class=MsoNormal align=center style='text-align:center'><span
995 style='font-size:20.0pt;mso-bidi-font-size:10.0pt'>Contents<o:p></o:p></span></p>
997 <p class=MsoNormal align=center style='text-align:center'><span
998 style='font-size:20.0pt;mso-bidi-font-size:10.0pt'><o:p>&nbsp;</o:p></span></p>
1000 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><!--[if supportFields]><span
1001 style='font-size:12.0pt;mso-bidi-font-size:10.0pt;text-transform:none'><span
1002 style='mso-element:field-begin'></span><span
1003 style='mso-spacerun:yes'> </span>TOC \o \n <span style='mso-element:field-separator'></span></span><![endif]--><span
1004 style='mso-no-proof:yes'>1.</span><span style='font-size:12.0pt;font-family:
1005 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1006 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1007 style='mso-no-proof:yes'>Introduction</span><span style='font-size:12.0pt;
1008 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1009 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1011 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1012 style='mso-no-proof:yes'>2.</span><span style='font-size:12.0pt;font-family:
1013 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1014 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1015 style='mso-no-proof:yes'>About eCos</span><span style='font-size:12.0pt;
1016 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1017 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1019 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1020 style='mso-no-proof:yes'>3.</span><span style='font-size:12.0pt;font-family:
1021 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1022 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1023 style='mso-no-proof:yes'>About the Nios II eCos Port</span><span
1024 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1025 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1027 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1028 style='mso-no-proof:yes'>4.</span><span style='font-size:12.0pt;font-family:
1029 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1030 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1031 style='mso-no-proof:yes'>Getting Help</span><span style='font-size:12.0pt;
1032 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1033 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1035 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1036 style='mso-no-proof:yes'>5.</span><span style='font-size:12.0pt;font-family:
1037 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1038 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1039 style='mso-no-proof:yes'>Installation Requirements</span><span
1040 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1041 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1043 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1044 style='mso-no-proof:yes'>6.</span><span style='font-size:12.0pt;font-family:
1045 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1046 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1047 style='mso-no-proof:yes'>Getting Started</span><span style='font-size:12.0pt;
1048 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1049 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1051 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1052 style='mso-no-proof:yes'>6.1</span><span style='font-size:12.0pt;font-family:
1053 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1054 style='mso-tab-count:1'>        </span></span><span style='mso-no-proof:yes'>Step
1055 1: Create the eCos Library</span><span style='font-size:12.0pt;font-family:
1056 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1058 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1059 style='mso-no-proof:yes'>6.2</span><span style='font-size:12.0pt;font-family:
1060 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1061 style='mso-tab-count:1'>        </span></span><span style='mso-no-proof:yes'>Step
1062 2: Build the Application</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1063 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1065 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1066 style='mso-no-proof:yes'>6.3</span><span style='font-size:12.0pt;font-family:
1067 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1068 style='mso-tab-count:1'>        </span></span><span style='mso-no-proof:yes'>Step
1069 3: Run the Application</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1070 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1072 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1073 style='mso-no-proof:yes'>7.</span><span style='font-size:12.0pt;font-family:
1074 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1075 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1076 style='mso-no-proof:yes'>Using the Nios II IDE</span><span style='font-size:
1077 12.0pt;font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";
1078 text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1080 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1081 style='mso-no-proof:yes'>8.</span><span style='font-size:12.0pt;font-family:
1082 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1083 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1084 style='mso-no-proof:yes'>Debug over JTAG</span><span style='font-size:12.0pt;
1085 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1086 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1088 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1089 style='mso-no-proof:yes'>8.1</span><span style='font-size:12.0pt;font-family:
1090 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1091 style='mso-tab-count:1'>        </span></span><span style='mso-no-proof:yes'>JTAG
1092 Debug Using the Nios II IDE</span><span style='font-size:12.0pt;font-family:
1093 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1095 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1096 style='mso-no-proof:yes'>8.2</span><span style='font-size:12.0pt;font-family:
1097 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1098 style='mso-tab-count:1'>        </span></span><span style='mso-no-proof:yes'>JTAG
1099 Debug Using <i style='mso-bidi-font-style:normal'>nios2-elf-insight</i></span><span
1100 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1101 "MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1103 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1104 style='mso-no-proof:yes'>9.</span><span style='font-size:12.0pt;font-family:
1105 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1106 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>       </span></span><span
1107 style='mso-no-proof:yes'>A Network Based Example</span><span style='font-size:
1108 12.0pt;font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";
1109 text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1111 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1112 style='mso-no-proof:yes'>10.</span><span style='font-size:12.0pt;font-family:
1113 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1114 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1115 style='mso-no-proof:yes'>Using Redboot</span><span style='font-size:12.0pt;
1116 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1117 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1119 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1120 style='mso-no-proof:yes'>10.1</span><span style='font-size:12.0pt;font-family:
1121 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1122 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Configuring
1123 and Building Redboot</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1124 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1126 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1127 style='mso-no-proof:yes'>10.2</span><span style='font-size:12.0pt;font-family:
1128 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1129 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Debugging
1130 Applications with Redboot</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1131 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1133 <p class=MsoToc3 style='tab-stops:60.0pt right dotted 431.5pt'><span
1134 style='mso-no-proof:yes'>10.2.1</span><span style='font-size:12.0pt;font-family:
1135 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1136 style='mso-tab-count:1'>    </span></span><span style='mso-no-proof:yes'>Debug
1137 Over Ethernet</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1138 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1140 <p class=MsoToc3 style='tab-stops:60.0pt right dotted 431.5pt'><span
1141 style='mso-no-proof:yes'>10.2.2</span><span style='font-size:12.0pt;font-family:
1142 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1143 style='mso-tab-count:1'>    </span></span><span style='mso-no-proof:yes'>Debug
1144 Over Serial</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1145 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1147 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1148 style='mso-no-proof:yes'>10.3</span><span style='font-size:12.0pt;font-family:
1149 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1150 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Redboot
1151 Memory Assignments</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1152 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1154 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1155 style='mso-no-proof:yes'>10.4</span><span style='font-size:12.0pt;font-family:
1156 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1157 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Booting
1158 Altera HAL Applications Using Redboot</span><span style='font-size:12.0pt;
1159 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:
1160 yes'><o:p></o:p></span></p>
1162 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1163 style='mso-no-proof:yes'>11.</span><span style='font-size:12.0pt;font-family:
1164 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1165 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1166 style='mso-no-proof:yes'>Accessing Character Devices</span><span
1167 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1168 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1170 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1171 style='mso-no-proof:yes'>12.</span><span style='font-size:12.0pt;font-family:
1172 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1173 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1174 style='mso-no-proof:yes'>Using the Compact Flash Interface</span><span
1175 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1176 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1178 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1179 style='mso-no-proof:yes'>12.1</span><span style='font-size:12.0pt;font-family:
1180 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1181 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Compact
1182 Flash Device Name</span><span style='font-size:12.0pt;font-family:"Times New Roman";
1183 mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><o:p></o:p></span></p>
1185 <p class=MsoToc2 style='tab-stops:48.0pt right dotted 431.5pt'><span
1186 style='mso-no-proof:yes'>12.2</span><span style='font-size:12.0pt;font-family:
1187 "Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:yes'><span
1188 style='mso-tab-count:1'>       </span></span><span style='mso-no-proof:yes'>Inserting
1189 and Removing Compact Flash Cards</span><span style='font-size:12.0pt;
1190 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";mso-no-proof:
1191 yes'><o:p></o:p></span></p>
1193 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1194 style='mso-no-proof:yes'>13.</span><span style='font-size:12.0pt;font-family:
1195 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1196 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1197 style='mso-no-proof:yes'>Changing Your Hardware Configuration</span><span
1198 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1199 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1201 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1202 style='mso-no-proof:yes'>14.</span><span style='font-size:12.0pt;font-family:
1203 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1204 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1205 style='mso-no-proof:yes'>Configtool and the Nios II IDE</span><span
1206 style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
1207 "MS Mincho";text-transform:none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1209 <p class=MsoToc1 style='tab-stops:30.0pt right dotted 6.0in'><span
1210 style='mso-no-proof:yes'>15.</span><span style='font-size:12.0pt;font-family:
1211 "Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:none;
1212 font-weight:normal;mso-no-proof:yes'><span style='mso-tab-count:1'>      </span></span><span
1213 style='mso-no-proof:yes'>Limitations</span><span style='font-size:12.0pt;
1214 font-family:"Times New Roman";mso-fareast-font-family:"MS Mincho";text-transform:
1215 none;font-weight:normal;mso-no-proof:yes'><o:p></o:p></span></p>
1217 <h1 style='margin-left:0in;text-indent:0in'><![if !supportLists]><span
1218 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1219 style='mso-list:Ignore'>1.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1220 </span></span></span><![endif]><!--[if supportFields]><span style='font-size:
1221 12.0pt;mso-bidi-font-size:10.0pt;mso-fareast-font-family:"Times New Roman";
1222 text-transform:uppercase;mso-font-kerning:0pt'><span style='mso-element:field-end'></span></span><![endif]--><a
1223 name="_Toc120958816"></a><a name="_Toc120958788"><span style='mso-bookmark:
1224 _Toc120958816'>Introduction</span></a></h1>
1226 <p class=MsoNormal>This is a port of the eCos operating system for the Nios II
1227 processor. The eCos operating system provides an effective software development
1228 platform for the Nios II family that incorporates an extensive range of
1229 middleware. </p>
1231 <p class=MsoNormal>eCos is an open source operating system specifically
1232 designed for use in the embedded environment. The licensing of the operating
1233 system is such that while changes to the kernel must be made public, the
1234 application does not. For more details see <a
1235 href="http://ecos.sourceware.org/license-overview.html">http://ecos.sourceware.org/license-overview.html</a>.</p>
1237 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958817"></a><a
1238 name="_Toc120958789"><span style='mso-bookmark:_Toc120958817'><![if !supportLists]><span
1239 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1240 style='mso-list:Ignore'>2.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1241 </span></span></span><![endif]>About eCos</span></a></h1>
1243 <p class=MsoNormal>eCos has been designed to support applications with
1244 real-time requirements, providing features such as full preemptability, minimal
1245 interrupt latencies, and all the necessary synchronization primitives,
1246 scheduling policies and interrupt handling mechanisms. eCos also provides all
1247 the functionality required for general embedded application support including
1248 device drivers, memory management, exception handling, C, math libraries, etc.
1249 In addition to runtime support, the eCos system includes all the tools necessary
1250 to develop embedded applications, including eCos software configuration and
1251 build tools, and GNU-based compilers, assemblers, linkers, debuggers, and
1252 simulators.</p>
1254 <p class=MsoNormal>eCos provides the following functionality:</p>
1256 <ul style='margin-top:0in' type=disc>
1257 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1258 list .5in'>Hardware Abstraction Layer (HAL) </li>
1259 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1260 list .5in'>Real-time kernel </li>
1261 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1262 list .5in'>Interrupt handling </li>
1263 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1264 list .5in'>Exception handling </li>
1265 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1266 list .5in'>Choice of schedulers </li>
1267 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1268 list .5in'>Thread support </li>
1269 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1270 list .5in'>Rich set of synchronization primitives </li>
1271 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1272 list .5in'>Timers, counters and alarms </li>
1273 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1274 list .5in'>Choice of memory allocators </li>
1275 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1276 list .5in'>Debug and instrumentation support </li>
1277 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1278 list .5in'><a href="http://www.ertl.jp/ITRON/home-e.html"><span
1279 style='color:windowtext;text-decoration:none;text-underline:none'>µITRON</span></a>
1280 3.0 compatible API </li>
1281 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1282 list .5in'>POSIX compatible API </li>
1283 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1284 list .5in'>ISO C and math libraries </li>
1285 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1286 list .5in'>Serial, Ethernet, wall-clock and watchdog device drivers</li>
1287 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1288 list .5in'>USB slave support </li>
1289 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1290 list .5in'>TCP/IP networking stacks, including Bootp/DHCP, DNS, TFTP/FTP,
1291 SNMP, IPv6 </li>
1292 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1293 list .5in'>HTTPD </li>
1294 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1295 list .5in'>File systems: </li>
1296 <ul style='margin-top:0in' type=circle>
1297 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1298 list 1.0in'><a href="http://sources.redhat.com/jffs2/"><span
1299 style='color:windowtext;text-decoration:none;text-underline:none'>Journaling
1300 Flash File System (JFFS2)</span></a> </li>
1301 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1302 list 1.0in'>RAM filing system </li>
1303 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1304 list 1.0in'>ROM filing system </li>
1305 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1306 list 1.0in'>FAT</li>
1307 </ul>
1308 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1309 list .5in'>Graphics libraries, including </li>
1310 <ul style='margin-top:0in' type=circle>
1311 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1312 list 1.0in'><a href="http://www.microwindows.org/"><span
1313 style='color:windowtext;text-decoration:none;text-underline:none'>Microwindows</span></a>
1314 </li>
1315 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level2 lfo3;tab-stops:
1316 list 1.0in'><a href="http://www.realvnc.com/what.html"><span
1317 style='color:windowtext;text-decoration:none;text-underline:none'>VNC
1318 Server</span></a> </li>
1319 </ul>
1320 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1321 list .5in'>Power management </li>
1322 <li class=MsoNormal style='margin-top:0in;mso-list:l3 level1 lfo3;tab-stops:
1323 list .5in'>GDB debug support </li>
1324 </ul>
1326 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958818"></a><a
1327 name="_Toc120958790"><span style='mso-bookmark:_Toc120958818'><![if !supportLists]><span
1328 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1329 style='mso-list:Ignore'>3.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1330 </span></span></span><![endif]>About the Nios II eCos port</span></a></h1>
1332 <p class=MsoNormal>The Nios II port of eCos is similar to other eCos
1333 architecture ports; however, there is one important difference. No platform or
1334 variant port is required for Nios II systems. Instead, hardware parameters and
1335 device drivers are automatically configured based on your SOPC builder system
1336 configuration. This greatly eases the task of beginning eCos development for
1337 Nios II on your own custom systems.</p>
1339 <p class=MsoNormal>This port provides support for the following Avalon
1340 peripheral components:</p>
1342 <ul style='margin-top:0in' type=disc>
1343 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>Timer</li>
1344 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>UART</li>
1345 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>JTAG
1346 UART</li>
1347 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>LAN91C111
1348 Ethernet chip</li>
1349 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>LCD
1350 16207 panel</li>
1351 <li class=MsoNormal style='mso-list:l2 level1 lfo4;tab-stops:list .5in'>Compact
1352 flash</li>
1353 </ul>
1355 <p class=MsoNormal>In addition, a driver is provided for the AM29LV065D flash
1356 device, included on the Nios Cyclone and Stratix development boards, and
1357 AM29LV128 flash device, used on the Nios Cyclone II and Stratix II. Drivers for
1358 other flash parts are provided with the eCos operating system, however these
1359 require manual configuration.</p>
1361 <p class=MsoNormal>The automatic configuration of your eCos project to match
1362 your SOPC builder system configuration is achieved using the <i
1363 style='mso-bidi-font-style:normal'>nios2configtool</i> utility. This is a
1364 wrapper for the standard eCos <i style='mso-bidi-font-style:normal'>configtool</i>
1365 utility. Using the <i style='mso-bidi-font-style:normal'>nios2configtool</i>
1366 constrains system configuration parameters and sets defaults to ensure they are
1367 valid for your hardware. The Getting Started section covers this in more
1368 detail.</p>
1370 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958819"></a><a
1371 name="_Toc120958791"></a><a name="_Ref82492711"><span style='mso-bookmark:_Toc120958791'><span
1372 style='mso-bookmark:_Toc120958819'><![if !supportLists]><span style='mso-fareast-font-family:
1373 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>4.<span
1374 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>Getting
1375 help</span></span></a></h1>
1377 <p class=MsoNormal>There is wealth of documentation available for eCos. The
1378 best place to start is in the online documentation beneath your installation,
1379 found in <a href="ecos-current/doc/html/index.html">ecos-current\doc\html\index.html</a>.
1380 This also contains a link to the most up to date version of these manuals. In
1381 addition there is a book available <u>Embedded<i style='mso-bidi-font-style:
1382 normal'> </i>Software Development with eCos</u> by Anthony J. Massa (ISBN
1383 0-13-035473-2).</p>
1385 <p class=MsoNormal>There is a large community of developers working on eCos and
1386 you can direct questions to the mailing lists at <a
1387 href="http://ecos.sourceware.org/intouch.html">http://ecos.sourceware.org/intouch.html</a>.
1388 In addition, the developers of this port monitor the Nios Community Forum <a
1389 href="http://www.niosforum.com/">www.niosforum.com</a>. There are also many
1390 companies who provide consultancy services based around eCos.</p>
1392 <p class=MsoNormal>For general Nios II issues, refer to the documentation
1393 provided with the <a href="../../documents/index.htm">Nios II kit</a>.</p>
1395 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958820"></a><a
1396 name="_Toc120958792"><span style='mso-bookmark:_Toc120958820'><![if !supportLists]><span
1397 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1398 style='mso-list:Ignore'>5.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1399 </span></span></span><![endif]>Installation requirements</span></a></h1>
1401 <p class=MsoNormal>This release of the Nios II port for eCos requires that you
1402 have the following software installed on your system:</p>
1404 <ul style='margin-top:0in' type=disc>
1405 <li class=MsoNormal style='mso-list:l5 level1 lfo5;tab-stops:list .5in'>Quartus
1406 II version 5.1</li>
1407 <li class=MsoNormal style='mso-list:l5 level1 lfo5;tab-stops:list .5in'>The
1408 Altera Nios II Development Kit version 5.1</li>
1409 </ul>
1411 <p class=MsoNormal>By default, the eCos installer will install eCos into you
1412 Nios II development kit. These instructions assume that this is the location
1413 you have selected.</p>
1415 <h1 style='margin-left:0in;text-indent:0in'><![if !supportLists]><span
1416 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1417 style='mso-list:Ignore'>6.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1418 </span></span></span><![endif]><span style='mso-spacerun:yes'> </span><a
1419 name="_Toc120958821"></a><a name="_Toc120958793"><span style='mso-bookmark:
1420 _Toc120958821'>Getting started</span></a></h1>
1422 <p class=MsoNormal>The following section describes how to build, download, and
1423 run an eCos application using Nios II. More extensive information on how to
1424 configure and use eCos can be found in the help sources detailed in section <span
1425 style='mso-field-code:" REF _Ref82492711 \\r \\h "'>4<!--[if gte mso 9]><xml>
1426 <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000000D0000005F00520065006600380032003400390032003700310031000000</w:data>
1427 </xml><![endif]--></span>.</p>
1429 <p class=MsoNormal>This discussion assumes that you are already familiar with
1430 the concepts involved in Nios II system design; you should first follow the
1431 tutorials provided with the <a href="../../documents/index.htm">Nios II kit</a>
1432 if you are not already familiar with Nios II design.</p>
1434 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958822"></a><a
1435 name="_Toc120958794"></a><a name="_Ref82503130"><span style='mso-bookmark:_Toc120958794'><span
1436 style='mso-bookmark:_Toc120958822'><![if !supportLists]><span style='mso-fareast-font-family:
1437 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>6.1<span
1438 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>Step
1439 1: Create the eCos library</span></span></a></h2>
1441 <p class=MsoNormal>The eCos operating system is normally configured using the
1442 eCos configuration tool, <i style='mso-bidi-font-style:normal'>configtool</i>.
1443 While this is still possible for Nios II, it is advisable instead to use the <i
1444 style='mso-bidi-font-style:normal'>nios2configtool</i> utility. This is a
1445 wrapper for <i style='mso-bidi-font-style:normal'>configtool</i>, which will
1446 set the default values of parameters to match your hardware configuration. It
1447 will also constrain the options presented for some parameters to ensure the
1448 value you select is appropriate for your hardware configuration.</p>
1450 <p class=MsoNormal><i style='mso-bidi-font-style:normal'>nios2configtool</i> is
1451 invoked from a Nios II SDK shell as follows:</p>
1453 <p class=MsoNormal align=center style='text-align:center'><span
1454 style='font-family:"Courier New"'>nios2configtool –-ptf=&lt;SOPC builder PTF
1455 file&gt; --cpu=&lt;name of CPU&gt;<o:p></o:p></span></p>
1457 <p class=MsoNormal><span style='mso-spacerun:yes'> </span>For example, if you
1458 are targeting the Cyclone 1C20 <i style='mso-bidi-font-style:normal'>standard</i>
1459 reference design included in your Nios II kit installation you should use:</p>
1461 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; nios2configtool
1462 --ptf=$SOPC_KIT_NIOS2/examples/verilog/niosII_cyclone_1c20/standard/std_1c20.ptf
1463 --cpu=cpu<o:p></o:p></span></p>
1465 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>The <i
1466 style='mso-bidi-font-style:normal'>configtool</i> window will then appear. You
1467 can find full documentation on how to use <i style='mso-bidi-font-style:normal'>configtool</i>
1468 under the configtool Help menu. You may need to select the internal documentation
1469 viewer: from View-&gt;Settings, on the Viewers tab, set “View documentation
1470 using” to “Built-in viewer”.<o:p></o:p></span></p>
1472 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>Note: For the
1473 purposes of the following tutorial steps, you should select a hardware design
1474 whose Nios II reset address is set to a flash memory device. This will allow
1475 you to program the application into flash and boot the application on reset.
1476 The <i style='mso-bidi-font-style:normal'>standard</i></span> and <i
1477 style='mso-bidi-font-style:normal'>full_featured</i> example designs for each
1478 Nios development board are already configured in this way.</p>
1480 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>To configure a
1481 project for a Nios II development board, select Build-&gt;Templates… from the
1482 tabs at the top of <i style='mso-bidi-font-style:normal'>configtool</i>. Set
1483 the hardware to be “Nios II Development Board (Altera)” and the packages to be
1484 “default”.<o:p></o:p></span></p>
1486 <p class=MsoNormal align=center style='text-align:center;page-break-after:avoid'><span
1487 style='mso-bidi-font-family:Arial'><!--[if gte vml 1]><v:shapetype id="_x0000_t75"
1488 coordsize="21600,21600" o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe"
1489 filled="f" stroked="f">
1490 <v:stroke joinstyle="miter"/>
1491 <v:formulas>
1492 <v:f eqn="if lineDrawn pixelLineWidth 0"/>
1493 <v:f eqn="sum @0 1 0"/>
1494 <v:f eqn="sum 0 0 @1"/>
1495 <v:f eqn="prod @2 1 2"/>
1496 <v:f eqn="prod @3 21600 pixelWidth"/>
1497 <v:f eqn="prod @3 21600 pixelHeight"/>
1498 <v:f eqn="sum @0 0 1"/>
1499 <v:f eqn="prod @6 1 2"/>
1500 <v:f eqn="prod @7 21600 pixelWidth"/>
1501 <v:f eqn="sum @8 21600 0"/>
1502 <v:f eqn="prod @7 21600 pixelHeight"/>
1503 <v:f eqn="sum @10 21600 0"/>
1504 </v:formulas>
1505 <v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect"/>
1506 <o:lock v:ext="edit" aspectratio="t"/>
1507 </v:shapetype><v:shape id="_x0000_i1025" type="#_x0000_t75" style='width:298.5pt;
1508 height:220.5pt'>
1509 <v:imagedata src="image001.png" o:title=""/>
1510 </v:shape><![endif]--><![if !vml]><img border=0 width=398 height=294
1511 src="image002.jpg" v:shapes="_x0000_i1025"><![endif]></span></p>
1513 <p class=MsoCaption align=center style='text-align:center'><a
1514 name="_Ref83543255">Figure </a><!--[if supportFields]><span style='mso-bookmark:
1515 _Ref83543255'></span><span style='mso-element:field-begin'></span><span
1516 style='mso-bookmark:_Ref83543255'><span style='mso-spacerun:yes'> </span>SEQ
1517 Figure \* ARABIC <span style='mso-element:field-separator'></span></span><![endif]--><span
1518 style='mso-bookmark:_Ref83543255'><span style='mso-no-proof:yes'>1</span></span><!--[if supportFields]><span
1519 style='mso-bookmark:_Ref83543255'></span><span style='mso-element:field-end'></span><![endif]--><span
1520 style='mso-bookmark:_Ref83543255'></span>: the configtool Templates window<span
1521 style='mso-bidi-font-family:Arial'><o:p></o:p></span></p>
1523 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'><o:p>&nbsp;</o:p></span></p>
1525 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>This will create
1526 project settings for your board using the standard set of eCos software
1527 packages.<o:p></o:p></span></p>
1529 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>For this tutorial,
1530 you will create a system that boots directly from flash and copied to RAM for
1531 execution. This option is located within the “Nios2 architecture” package,
1532 which is located beneath the “eCos HAL” package in <i style='mso-bidi-font-style:
1533 normal'>configtool</i>, as illustrated in <span style='mso-field-code:" REF _Ref82502150 \\h "'><span
1534 style='mso-bidi-font-family:"Times New Roman"'>Figure <span style='mso-no-proof:
1535 yes'>2</span></span><!--[if gte mso 9]><xml>
1536 <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000000D0000005F00520065006600380032003500300032003100350030000000</w:data>
1537 </xml><![endif]--></span>.<o:p></o:p></span></p>
1539 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>One thing to note
1540 here is that <i style='mso-bidi-font-style:normal'>configtool</i> has a quirk
1541 where after changing parameters it is necessary to click somewhere else in the
1542 display, for the change to take effect.<o:p></o:p></span></p>
1544 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>Having configured
1545 the operating system as required, you can now build the eCos library. To do
1546 this select the Build-&gt;Library tab in configtool. You will be asked for a
1547 location to save the project. When you provide this, be aware that <i
1548 style='mso-bidi-font-style:normal'>configtool</i> will create folders in the
1549 same directory. These will be used to store the build products.<o:p></o:p></span></p>
1551 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>Once the build is
1552 complete, you will have constructed an eCos library tailored to your hardware configuration.
1553 Be sure to scroll back in the output window to ensure that the build procedure
1554 did complete without errors.<o:p></o:p></span></p>
1556 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>Note: Making
1557 changes to your hardware design (i.e., in SOPC Builder) will <b
1558 style='mso-bidi-font-weight:normal'>not </b>rebuild the eCos library. After
1559 making any changes to your SOPC Builder design and Quartus II compilation, you
1560 should re-open <i style='mso-bidi-font-style:normal'>nios2configtool</i> and
1561 perform “clean” and “build” operations to refresh the eCos library. This will
1562 ensure that the eCos operating system and library reflect any system changes.
1563 This behavior differs from the Nios II IDE projects that include a system
1564 library (non-eCos) project, which are automatically re-compiled during builds
1565 after a change in the underlying hardware.<b style='mso-bidi-font-weight:normal'><o:p></o:p></b></span></p>
1567 <p class=MsoNormal align=center style='text-align:center;page-break-after:avoid'><span
1568 style='mso-bidi-font-family:Arial'><!--[if gte vml 1]><v:shape id="_x0000_i1026"
1569 type="#_x0000_t75" style='width:369pt;height:328.5pt'>
1570 <v:imagedata src="image003.png" o:title=""/>
1571 </v:shape><![endif]--><![if !vml]><img border=0 width=492 height=438
1572 src="image004.jpg" v:shapes="_x0000_i1026"><![endif]></span></p>
1574 <p class=MsoCaption align=center style='text-align:center'><a
1575 name="_Ref82502150">Figure </a><!--[if supportFields]><span style='mso-bookmark:
1576 _Ref82502150'></span><span style='mso-element:field-begin'></span><span
1577 style='mso-bookmark:_Ref82502150'><span style='mso-spacerun:yes'> </span>SEQ
1578 Figure \* ARABIC <span style='mso-element:field-separator'></span></span><![endif]--><span
1579 style='mso-bookmark:_Ref82502150'><span style='mso-no-proof:yes'>2</span></span><!--[if supportFields]><span
1580 style='mso-bookmark:_Ref82502150'></span><span style='mso-element:field-end'></span><![endif]--><span
1581 style='mso-bookmark:_Ref82502150'></span>: Illustration of the location of the
1582 &quot;startup type&quot; option<span style='mso-bidi-font-family:Arial'><o:p></o:p></span></p>
1584 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958823"></a><a
1585 name="_Toc120958795"><span style='mso-bookmark:_Toc120958823'><![if !supportLists]><span
1586 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1587 style='mso-list:Ignore'>6.2<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1588 </span></span></span><![endif]>Step 2: Build the application</span></a></h2>
1590 <p class=MsoNormal>eCos includes some simple example applications. You can find
1591 these in the examples directory beneath the eCos install directory. First, copy
1592 the contents of this example directory to a location outside of the Nios II kit
1593 directory. You can now build these examples, using the library created in
1594 section 6.1. To do so, open a Nios II SDK shell. Then change into the directory
1595 containing your copy of the examples.</p>
1597 <p class=MsoNormal>The examples are built using the GNU <i style='mso-bidi-font-style:
1598 normal'>make</i> utility. You will need to provide on the command line the
1599 location of the eCos install directory. This was created when you built your
1600 eCos library. For example, if you saved your eCos project in /<i
1601 style='mso-bidi-font-style:normal'>cygdrive/c/ecos/example.ecc</i>, then you
1602 should build the examples using:</p>
1604 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; make
1605 INSTALL_DIR=/cygdrive/c/ecos/example_install <o:p></o:p></span></p>
1607 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>This will build a
1608 number of example applications, including an application named “hello”. This
1609 example will send the message, </span>“Hello, eCos world!” <span
1610 style='mso-bidi-font-family:Arial'>to the console device. The following
1611 discussion explains how to run and debug this application. You can use the same
1612 procedure for any of the other examples as well.<o:p></o:p></span></p>
1614 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958824"></a><a
1615 name="_Toc120958796"></a><a name="_Ref83548101"><span style='mso-bookmark:_Toc120958796'><span
1616 style='mso-bookmark:_Toc120958824'><![if !supportLists]><span style='mso-fareast-font-family:
1617 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>6.3<span
1618 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>Step
1619 3: Run the application</span></span></a></h2>
1621 <p class=MsoNormal>You can program an application into flash using the <i
1622 style='mso-bidi-font-style:normal'><span style='mso-bidi-font-family:Arial'>program_flash</span></i>
1623 script. This is an automatically generated shell script built with your eCos
1624 library. This script is only built if you are targeting either a “ROM” or
1625 “ROMRAM” configuration.</p>
1627 <p class=MsoNormal>This script uses the Altera <i style='mso-bidi-font-style:
1628 normal'>nios2-flash-programmer</i> utility to program your executable into
1629 flash. The first argument (required) to the script is the name of the
1630 executable (.elf) file to use. The second argument (optional) is the name of an
1631 FPGA programming (.sof) file to download to the target FPGA before programming
1632 flash. If you do not provide the optional .sof argument, you must configure the
1633 target using some other means (Quartus II Programmer utility, power-on flash
1634 configuration, etc.) before programming flash. The <i style='mso-bidi-font-style:
1635 normal'>program_flash</i> script is located in the install directory associated
1636 with your eCos <i style='mso-bidi-font-style:normal'>configtool</i> project.</p>
1638 <p class=MsoNormal>To program the “hello” example created in section 6.2,
1639 execute the command:</p>
1641 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt;
1642 /cygdrive/c/ecos/example_install/program_flash hello <o:p></o:p></span></p>
1644 <p class=MsoNormal>The path to the install directory is the path to the project
1645 you created in section 5.1.</p>
1647 <p class=MsoNormal>Note that you must not have any <i style='mso-bidi-font-style:
1648 normal'>nios2-terminal</i> or JTAG based debug session connected to your board
1649 when you attempt to run <i style='mso-bidi-font-style:normal'>program_flash</i>.</p>
1651 <p class=MsoNormal>Having run the <i style='mso-bidi-font-style:normal'>program_flash</i>
1652 utility, you will need to reset the Nios II CPU to start eCos execution. This
1653 is done by pressing the “CPU Reset” button on your development board.
1654 Alternatively, you may power-cycle the board. Your hardware design’s .sof file
1655 must then be downloaded again using the Quartus II Programmer, unless the FPGA
1656 configuration is also stored in flash.</p>
1658 <p class=MsoNormal>By default, Nios II eCos projects use a JTAG UART as the
1659 console device. This is a configurable option, which is set using <i
1660 style='mso-bidi-font-style:normal'>nios2configtool</i>. To view the output from
1661 the JTAG UART, you will need to open a terminal for the device. This is done by
1662 running:</p>
1664 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; nios2-terminal<o:p></o:p></span></p>
1666 <p class=MsoNormal>Having opened a terminal, you should see the message:
1667 “Hello, eCos world!” appear.</p>
1669 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958825"></a><a
1670 name="_Toc120958797"><span style='mso-bookmark:_Toc120958825'><![if !supportLists]><span
1671 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1672 style='mso-list:Ignore'>7.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1673 </span></span></span><![endif]>Using the Nios II IDE</span></a></h1>
1675 <p class=MsoNormal>It is possible to build eCos applications from within the
1676 Nios II IDE using an “Advanced C/C++ Project”. To illustrate this, the steps
1677 detailed below describe how to import and build the example eCos applications.</p>
1679 <p class=MsoNormal>Note that for this procedure to succeed, you must use a copy
1680 of the examples directory located outside of the Nios II kit directory. It is
1681 not possible to directly import the examples installed with eCos.</p>
1683 <p class=MsoNormal>From the “File” menu at the top of the Nios II IDE, select
1684 New-&gt;Project… This will display the new project wizard. Select “Altera Nios
1685 II” in the pane on the left, and “Advanced C/C++ Project” in the pane on the
1686 right, and then click “Next”. Give your project a name, e.g. <i
1687 style='mso-bidi-font-style:normal'>ecos_hello</i>, and unselect the “Use
1688 Default Location” check box. You can then use the browse button to browse to
1689 the location of the example project you built following the instructions above.
1690 Then click “Next”.</p>
1692 <p class=MsoNormal>Select the “Make Builder” tab, and then set the build
1693 command to be the make command as described above, for example:</p>
1695 <p class=MsoNormal><span style='font-family:"Courier New"'>make
1696 INSTALL_DIR=/cygdrive/c/ecos/example_install <o:p></o:p></span></p>
1698 <p class=MsoNormal>Then click “Finish”.</p>
1700 <p class=MsoNormal>You will then be able to build the project from the IDE as
1701 you would any other IDE based software project. Instructions for creating a
1702 Run/Debug configuration are given in the next section.</p>
1704 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958826"></a><a
1705 name="_Toc120958798"><span style='mso-bookmark:_Toc120958826'><![if !supportLists]><span
1706 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1707 style='mso-list:Ignore'>8.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1708 </span></span></span><![endif]>Debug over JTAG</span></a></h1>
1710 <p class=MsoNormal>Applications built using a “ROMRAM” (boot from flash, copy to
1711 RAM) configuration can be debugged using the Altera JTAG-based debugger.
1712 Applications that built using a “ROM” (boot and execute from flash)
1713 configuration can also be debugged, but this will require use of hardware
1714 breakpoints. Details on how to use hardware breakpoints are discussed in the
1715 FS2 System Analyzer documentation supplied with the Nios II kit (see <a
1716 href="../../documents/html_content/documentation.htm">documents\html_content\documentation.htm</a>).</p>
1718 <p class=MsoNormal>The following discussion assumes you are using a “ROMRAM”
1719 configuration.</p>
1721 <p class=MsoNormal>There are three approaches available for using the Altera
1722 JTAG debugger for Nios II. You can either debug the application using: the Nios
1723 II IDE, <i style='mso-bidi-font-style:normal'>nios2-elf-insight</i>, or <i
1724 style='mso-bidi-font-style:normal'>nios2-elf-gdb</i>. Full documentation for
1725 these debuggers is provided with the Nios II kit, and can be accessed from the
1726 documentation page referenced above.</p>
1728 <p class=MsoNormal>Detailed here is how to launch a debug session using the
1729 Nios II IDE, and the <i style='mso-bidi-font-style:normal'>nios2-elf-insight</i>
1730 application.</p>
1732 <p class=MsoNormal>Note that when debugging an application in this way, you do
1733 not need to program the application into flash. The application is directly
1734 loaded into RAM by the debugger.</p>
1736 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958827"></a><a
1737 name="_Toc120958799"><span style='mso-bookmark:_Toc120958827'><![if !supportLists]><span
1738 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1739 style='mso-list:Ignore'>8.1<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1740 </span></span></span><![endif]>JTAG debug using the Nios II IDE</span></a></h2>
1742 <p class=MsoNormal>The first step in debugging an application using the Nios II
1743 IDE is to import your application project into the IDE, as described in section
1744 7. You can then create a debug configuration associated with this project. </p>
1746 <p class=MsoNormal>From the “Run” menu, select “Debug…” (not “Debug”). This
1747 will then display the available set of debug launch configurations. Click “New”
1748 to create a new Nios II Hardware configuration. Set the project to be the
1749 project you created following the instructions given above, and set the
1750 executable to be “hello”. Specify the SOPC builder system, and the CPU name to
1751 match the parameters you passed to <i style='mso-bidi-font-style:normal'>nios2configtool</i>.
1752 Then select the “Target Connection” tab.</p>
1754 <p class=MsoNormal>On the “Target Connection” tab, set the Nios II terminal
1755 communication device to be the device you are using for the console, e.g.
1756 “jtag_uart”. Then click “Debug”.</p>
1758 <p class=MsoNormal>This will launch the debug session. You can then proceed to
1759 debug your eCos application as you would any other Nios II application. See the
1760 Nios II IDE online help for further information.</p>
1762 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958828"></a><a
1763 name="_Toc120958800"><span style='mso-bookmark:_Toc120958828'><![if !supportLists]><span
1764 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1765 style='mso-list:Ignore'>8.2<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1766 </span></span></span><![endif]>JTAG debug using </span></a>Insight</h2>
1768 <p class=MsoNormal>To debug an application using <i style='mso-bidi-font-style:
1769 normal'>nios2-elf-insight</i>, you should first launch <i style='mso-bidi-font-style:
1770 normal'>nios2-gdb-server</i> to establish a JTAG connection to the board. This
1771 is done by running the following command from within an SDK shell:</p>
1773 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt;
1774 nios2-gdb-server –-tcpport=2343 &amp;<o:p></o:p></span></p>
1776 <p class=MsoNormal>To debug an application named “hello” in the current
1777 directory, you should then run:</p>
1779 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; nios2-elf-insight
1780 hello<o:p></o:p></span></p>
1782 <p class=MsoNormal><span style='mso-bidi-font-family:Arial'>This will launch
1783 the insight debug interface. To connect to the board, open the GDB console by
1784 selecting “Console” from the “view” menu. Then type the following commands:<o:p></o:p></span></p>
1786 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; target remote
1787 :2343<o:p></o:p></span></p>
1789 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; load<o:p></o:p></span></p>
1791 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; break main<o:p></o:p></span></p>
1793 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; jump *_start <o:p></o:p></span></p>
1795 <p class=MsoNormal>This will: establish a connection to the target; download
1796 the executable; set a breakpoint at main; and then begin execution.</p>
1798 <p class=MsoNormal>You can use these same commands when using <i
1799 style='mso-bidi-font-style:normal'>nios2-elf-gdb</i> in place of <i
1800 style='mso-bidi-font-style:normal'>nios2-elf-insight</i>.</p>
1802 <p class=MsoNormal>From here, it is then possible to step, break, continue etc.
1803 You can find further information the Insight online help (select “help” at the
1804 top of the Insight window).</p>
1806 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958829"></a><a
1807 name="_Toc120958801"><span style='mso-bookmark:_Toc120958829'><![if !supportLists]><span
1808 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1809 style='mso-list:Ignore'>9.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1810 </span></span></span><![endif]>Network-based example</span></a>s</h1>
1812 <p class=MsoNormal>eCos provides an HTTP web server component that can be used
1813 to serve web pages which include dynamically generated content. Additional
1814 details of how to use this feature can be found in the “Embedded HTTP Server”
1815 chapter of the <a href="ecos-current/doc/html/ref/ecos-ref.html">eCos Reference
1816 Manual</a>. The following instructions describe how to run the web server demo
1817 on a Nios II based system. These instructions assume you have an <i
1818 style='mso-bidi-font-style:normal'>altera_avalon_lan91c111</i> Ethernet device
1819 within your SOPC builder system.</p>
1821 <p class=MsoNormal>First, you should create a new project by selecting “New”
1822 beneath the “File” menu in <i style='mso-bidi-font-style:normal'>configtool</i>.
1823 Then, select “Templates…” beneath the “Build” menu. Within the Templates
1824 window, set the Hardware to “Nios II Development Board (Altera)” and select the
1825 “net” packages. Select “OK” and accept any suggested conflict resolutions by
1826 pressing continue.</p>
1828 <p class=MsoNormal>You can then add the HTTP server package by selecting
1829 “Packages” beneath the “Build” menu. Add the “HTTP Server” package, and the
1830 click “OK”.</p>
1832 <p class=MsoNormal>You can then save, and build this library. You can use this
1833 library can be used to build and run examples such as the <i style='mso-bidi-font-style:
1834 normal'>hello</i> application. However, you must do a make clean to delete the
1835 old files. For example:</p>
1837 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; make
1838 INSTALL_DIR=/cygdrive/c/ecos/example_net_install clean<o:p></o:p></span></p>
1840 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; make
1841 INSTALL_DIR=/cygdrive/c/ecos/example_net_install</span></p>
1843 <p class=MsoNormal>When you run the <i style='mso-bidi-font-style:normal'>hello</i>
1844 application, an additional monitor thread will be created which is used to
1845 serve the example web content. For this to function correctly, you must have
1846 correctly configured your network. By default, the internet protocol (IP)
1847 address of the board will be determined automatically at boot time using the
1848 DHCP protocol. If you do not have a DHCP server available, or you want to use a
1849 fixed IP address, you must configure your eCos library with the appropriate
1850 parameters. You can find these parameters in <i style='mso-bidi-font-style:
1851 normal'>configtool</i> within the “Basic networking framework” package, as
1852 illustrated in <span style='mso-field-code:" REF _Ref83543261 \\h "'>Figure <span
1853 style='mso-no-proof:yes'>3</span><!--[if gte mso 9]><xml>
1854 <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000000D0000005F00520065006600380033003500340033003200360031000000</w:data>
1855 </xml><![endif]--></span>.</p>
1857 <p class=MsoNormal><o:p>&nbsp;</o:p></p>
1859 <p class=MsoNormal align=center style='text-align:center;page-break-after:avoid'><!--[if gte vml 1]><v:shape
1860 id="_x0000_i1027" type="#_x0000_t75" style='width:333pt;height:337.5pt'>
1861 <v:imagedata src="image005.png" o:title=""/>
1862 </v:shape><![endif]--><![if !vml]><img border=0 width=444 height=450
1863 src="image006.jpg" v:shapes="_x0000_i1027"><![endif]></p>
1865 <p class=MsoCaption align=center style='text-align:center'><a
1866 name="_Ref83543261">Figure </a><!--[if supportFields]><span style='mso-bookmark:
1867 _Ref83543261'></span><span style='mso-element:field-begin'></span><span
1868 style='mso-bookmark:_Ref83543261'><span style='mso-spacerun:yes'> </span>SEQ
1869 Figure \* ARABIC <span style='mso-element:field-separator'></span></span><![endif]--><span
1870 style='mso-bookmark:_Ref83543261'><span style='mso-no-proof:yes'>3</span></span><!--[if supportFields]><span
1871 style='mso-bookmark:_Ref83543261'></span><span style='mso-element:field-end'></span><![endif]--><span
1872 style='mso-bookmark:_Ref83543261'></span>: Location of the network
1873 configuration parameters</p>
1875 <p class=MsoNormal>When your application is running, and correctly connected to
1876 the network, you can access the example monitor web content using a web
1877 browser. The URL is the IP address of your board followed by “/monitor”, e.g. <a
1878 href="http://192.168.1.2/monitor">http://192.168.1.2/monitor</a>.</p>
1880 <p class=MsoNormal>For further information on the eCos HTTP server, refer to
1881 the <a href="ecos-current/doc/html/ref/ecos-ref.html">eCos Reference Manual</a>.</p>
1883 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958830"></a><a
1884 name="_Toc120958802"></a><a name="_Ref82501518"><span style='mso-bookmark:_Toc120958802'><span
1885 style='mso-bookmark:_Toc120958830'><![if !supportLists]><span style='mso-fareast-font-family:
1886 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>10.<span
1887 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>Using
1888 Redboot</span></span></a></h1>
1890 <p class=MsoNormal>Redboot is an eCos application that provides a complete
1891 bootstrap environment for a range of embedded operating systems, such as
1892 embedded Linux and eCos, and includes facilities such as network downloading
1893 and debugging. It also provides a simple flash file system for boot images. You
1894 can find full documentation on the use of Redboot in the <a
1895 href="ecos-current/doc/html/ref/ecos-ref.html">eCos Reference Manual</a>.</p>
1897 <p class=MsoNormal>Redboot can be a useful tool during eCos development, where
1898 it acts as a GDB debug stub. It is also useful in production systems where
1899 field upgradeability is important.</p>
1901 <p class=MsoNormal>This section describes how to build and run Redboot for Nios
1902 II. In addition, it describes how it can be used to provide thread aware debug
1903 for eCos applications.</p>
1905 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958831"></a><a
1906 name="_Toc120958803"></a><a name="_Ref83548311"><span style='mso-bookmark:_Toc120958803'><span
1907 style='mso-bookmark:_Toc120958831'><![if !supportLists]><span style='mso-fareast-font-family:
1908 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>10.1<span
1909 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>Configuring
1910 and building Redboot</span></span></a></h2>
1912 <p class=MsoNormal>If you are targeting your own custom hardware design, it is
1913 advisable to create a basic Redboot configuration using the “Redboot” template
1914 in <i style='mso-bidi-font-style:normal'>configtool</i>. You can then add
1915 additional packages, such as flash or networking support as required.</p>
1917 <p class=MsoNormal>However, if you are using one of the Altera <i
1918 style='mso-bidi-font-style:normal'>standard</i> or <i style='mso-bidi-font-style:
1919 normal'>full_featured</i> reference designs, you can start with the Redboot
1920 configuration files supplied with eCos. These can be found in the directory:
1921 $ECOS_REPOSITORY/hal/nios2/arch/current/misc. $ECOS_REPOSITORY is an
1922 environment variable pointing at your eCos packages, for example the default
1923 install can be found at c:\altera\kits\nios2\components\eCos\ecos-current\packages.</p>
1925 <p class=MsoNormal>There are two configurations available: <i style='mso-bidi-font-style:
1926 normal'>redboot_ROM.ecm</i> and <i style='mso-bidi-font-style:normal'>redboot_ROMRAM.ecm</i>.
1927 As their names suggest, the first can be used to create a “ROM” based Redboot
1928 configuration, and the second can be used to create a “ROMRAM” based
1929 configuration.</p>
1931 <p class=MsoNormal>To create a project using one of these configurations, first
1932 select “New” from the “File” menu to create a new project. Then select the
1933 “redboot” template in the configtool “Build-&gt;Templates…” window, a window
1934 will pop up asking you to resolve conflicts, just take the recommended solution
1935 by pressing continue . Having done this, you can import the configuration by
1936 selecting “Import…” from the configtool “File” menu, and then browse to the
1937 required configuration file, again a window will pop up asking you to Resolve
1938 conflicts, once again take the recommended solution by pressing continue.</p>
1940 <p class=MsoNormal>Having created the Redboot configuration, save and build the
1941 project using <i style='mso-bidi-font-style:normal'>configtool</i> as before.</p>
1943 <p class=MsoNormal>Building the project will create an executable (elf) file, <i
1944 style='mso-bidi-font-style:normal'>redboot.elf</i>. You can program this into
1945 flash by opening an SDK shell, and changing into the install directory created
1946 when you built your Redboot project. Then issue the command:</p>
1948 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; ./program_flash
1949 bin/redboot.elf<o:p></o:p></span></p>
1951 <p class=MsoNormal>Following this, you will need to re-program your FPGA
1952 configuration (if necessary) and connect a terminal, as described in section <span
1953 style='mso-field-code:" REF _Ref83548101 \\r \\h "'>6.3<!--[if gte mso 9]><xml>
1954 <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000000D0000005F00520065006600380033003500340038003100300031000000</w:data>
1955 </xml><![endif]--></span>.</p>
1957 <p class=MsoNormal>The first time you run Redboot, the program will fail to
1958 find valid configuration data in flash. You can set the flash configuration
1959 data by running the command:</p>
1961 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; fconfig<o:p></o:p></span></p>
1963 <p class=MsoNormal>at the Redboot prompt. This configuration data includes
1964 network configuration parameters, if you wish to debug over Ethernet you will
1965 need to set up an IP Address.<span style='font-family:"Courier New"'><o:p></o:p></span></p>
1967 <p class=MsoNormal>For details on the use and meanings of the options that are
1968 presented, see the Redboot documentation. This is contained within the eCos
1969 Reference Manual.</p>
1971 <p class=MsoNormal>Running the command:</p>
1973 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; help <o:p></o:p></span></p>
1975 <p class=MsoNormal>at the Redboot prompt will display a list of the available
1976 commands.</p>
1978 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958832"></a><a
1979 name="_Toc120958804"><span style='mso-bookmark:_Toc120958832'><![if !supportLists]><span
1980 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
1981 style='mso-list:Ignore'>10.2<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
1982 </span></span></span><![endif]>Debugging applications with Redboot</span></a></h2>
1984 <p class=MsoNormal>The configuration files: <i style='mso-bidi-font-style:normal'>redboot_ROM.ecm</i>
1985 and <i style='mso-bidi-font-style:normal'>redboot_ROMRAM.ecm</i> will configure
1986 your Redboot application to include the GDB stubs. Using this rather than the
1987 JTAG based debugger will allow you to access thread information and set thread
1988 specific breakpoints while debugging.</p>
1990 <p class=MsoNormal>If you wish to build an application that is suitable for
1991 downloading via Redboot, you should select the “RAM” configuration. You can
1992 then build the application as described above. The executable can be loaded
1993 directly by Redboot, for example over the network using TFTP, or through a GDB
1994 based debugger.</p>
1996 <p class=MsoNormal>Currently the only available debuggers are <i
1997 style='mso-bidi-font-style:normal'>nios2-elf-insight</i> and <i
1998 style='mso-bidi-font-style:normal'>nios2-elf-gdb</i>. You cannot use the
1999 debugger in the Nios II IDE, since this does not support debug over either
2000 serial or Ethernet, required by Redboot.</p>
2002 <h3 style='margin-left:0in;text-indent:0in'><a name="_Toc120958833"></a><a
2003 name="_Toc120958805"><span style='mso-bookmark:_Toc120958833'><![if !supportLists]><span
2004 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2005 style='mso-list:Ignore'>10.2.1<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2006 </span></span></span><![endif]>Debug over Ethernet</span></a></h3>
2008 <p class=MsoNormal>The Redboot network configuration parameters are set using
2009 the <i style='mso-bidi-font-style:normal'>fconfig</i> command, as described in
2010 section <span style='mso-field-code:" REF _Ref83548311 \\r \\h "'>10.1<!--[if gte mso 9]><xml>
2011 <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000000D0000005F00520065006600380033003500340038003300310031000000</w:data>
2012 </xml><![endif]--></span>. You should verify that your network configuration is
2013 correct by using the <i style='mso-bidi-font-style:normal'>ping</i> utility.
2014 Ensure that you can ping from your PC to the target board and from the board to
2015 your PC.</p>
2017 <p class=MsoNormal>Having established that you have a valid network connection,
2018 you can start a debug session using <i style='mso-bidi-font-style:normal'>nios2-elf-insight</i>
2019 by typing:</p>
2021 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt;
2022 nios2-elf-insight hello<o:p></o:p></span></p>
2024 <p class=MsoNormal>in an SDK shell. Note that you do not need to run <i
2025 style='mso-bidi-font-style:normal'>nios2-gdb-server</i>, as is required when
2026 debugging over JTAG.</p>
2028 <p class=MsoNormal>In the GDB console, you can then issue the following
2029 commands to connect to the board, download the application, and then run to a
2030 breakpoint at <i style='mso-bidi-font-style:normal'>main()</i>:</p>
2032 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; target remote
2033 11.22.33.44:9000 <o:p></o:p></span></p>
2035 <p class=MsoNormal>where “11.22.33.44” is the IP Address assigned to the board
2036 using the <i style='mso-bidi-font-style:normal'>fconfig</i> command in section
2037 9.1</p>
2039 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; load<o:p></o:p></span></p>
2041 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; break main<o:p></o:p></span></p>
2043 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; jump *_start <o:p></o:p></span></p>
2045 <p class=MsoNormal>This example assumes that you have configured Redboot, using
2046 the <i style='mso-bidi-font-style:normal'>fconfig</i> command, to have an IP
2047 address of “11.22.33.44” and a GDB connection port of 9000.</p>
2049 <p class=MsoNormal>See the Insight documentation for details on how to use the
2050 thread-aware debug features.</p>
2052 <h3 style='margin-left:0in;text-indent:0in'><a name="_Toc120958834"></a><a
2053 name="_Toc120958806"><span style='mso-bookmark:_Toc120958834'><![if !supportLists]><span
2054 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2055 style='mso-list:Ignore'>10.2.2<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2056 </span></span></span><![endif]>Debug over serial</span></a></h3>
2058 <p class=MsoNormal>The procedure for debug over serial is very similar to the
2059 procedure for debug over Ethernet as described above. You should use this if
2060 you wish to debug applications that use network facilities.</p>
2062 <p class=MsoNormal>First, connect the serial port on your board (labeled
2063 “console” on the Altera Nios II development boards) to one of the serial ports
2064 in your PC. This example assumes that you are using COM1. Then launch <i
2065 style='mso-bidi-font-style:normal'>nios2-elf-insight</i> as before, and type
2066 the following commands at the GDB console:</p>
2068 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; set remotebaud
2069 115200<o:p></o:p></span></p>
2071 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; target remote
2072 COM1<o:p></o:p></span></p>
2074 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; load<o:p></o:p></span></p>
2076 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; break main<o:p></o:p></span></p>
2078 <p class=MsoNormal><span style='font-family:"Courier New"'>&gt; jump *_start <o:p></o:p></span></p>
2080 <p class=MsoNormal>The baud rate of the serial port used is determined by the
2081 SOPC builder project. In the Altera reference designs it is set to be 115200,
2082 as used above.</p>
2084 <p class=MsoNormal>Note that there can be a significant delay in establishing
2085 the initial connection to the board when using a serial connection.</p>
2087 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958835"></a><a
2088 name="_Toc120958807"><span style='mso-bookmark:_Toc120958835'><![if !supportLists]><span
2089 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2090 style='mso-list:Ignore'>10.3<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2091 </span></span></span><![endif]>Redboot memory assignments</span></a></h2>
2093 <p class=MsoNormal>It is important to ensure that download eCos applications do
2094 not use memory required by Redboot. Memory is reserved for the Redboot monitor
2095 by the downloaded application using options set in <i style='mso-bidi-font-style:
2096 normal'>configtool</i>. The options are located within the “eCos HAL” package,
2097 beneath the “ROM monitor support” folder. </p>
2099 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958836"></a><a
2100 name="_Toc120958808"><span style='mso-bookmark:_Toc120958836'><![if !supportLists]><span
2101 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2102 style='mso-list:Ignore'>10.4<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2103 </span></span></span><![endif]>Booting Altera HAL applications with Redboot</span></a></h2>
2105 <p class=MsoNormal>Redboot is not restricted to booting eCos applications.
2106 Redboot can also boot applications built using other operating systems. This section
2107 describes how to use Redboot to boot applications that have been built using
2108 the Altera Hardware Abstraction Layer (HAL), and Altera HAL based operating
2109 systems such as MicroC/OS-II, ThreadX, PrKernelv4 and others.</p>
2111 <p class=MsoNormal>Booting HAL based applications using Redboot provides a
2112 multi-stage boot-flow that may be useful in a number of development and
2113 production systems. Using Redboot allows, for example, Altera HAL based
2114 applications to be booted over the network. It also provides a mechanism for
2115 remote upgrade of HAL based applications and hardware images stored in flash.</p>
2117 <p class=MsoNormal>Since the Altera HAL does not include GDB stubs support,
2118 Redboot cannot be used to debug HAL based systems.</p>
2120 <p class=MsoNormal>In creating a system that uses Redboot to load HAL
2121 applications, you must apply some constraints to your system design. Most
2122 importantly, it is necessary to ensure that the memory used by Redboot does not
2123 overlap the memory required by the downloaded code. The steps required to
2124 ensure this are given below.</p>
2126 <p class=MsoNormal style='margin-left:52.8pt;text-indent:-.25in;mso-list:l4 level1 lfo6;
2127 tab-stops:list 52.8pt'><![if !supportLists]><span style='mso-fareast-font-family:
2128 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>1.<span
2129 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>The
2130 hardware exceptions vector set in the SOPC builder project must be located in a
2131 writeable RAM region.</p>
2133 <p class=MsoNormal style='margin-left:52.8pt;text-indent:-.25in;mso-list:l4 level1 lfo6;
2134 tab-stops:list 52.8pt'><![if !supportLists]><span style='mso-fareast-font-family:
2135 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>2.<span
2136 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>The
2137 memory module used for the exception vector must not overlap the modules used
2138 by Redboot. The memory regions used by Redboot are set in configtool using the
2139 “text region”, “rodata region”, and “rwdata region”. These are located in the
2140 “Nios 2 architecture” package, which is located beneath “eCos HAL”.</p>
2142 <p class=MsoNormal style='margin-left:52.8pt;text-indent:-.25in;mso-list:l4 level1 lfo6;
2143 tab-stops:list 52.8pt'><![if !supportLists]><span style='mso-fareast-font-family:
2144 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>3.<span
2145 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>The
2146 memory regions used by the downloaded Altera HAL application must not overlap
2147 the regions used by Redboot. They can use the same region used for the
2148 exception vector. The memory regions used by an Altera HAL application are set
2149 on the System Library Properties page in the Nios II IDE.</p>
2151 <p class=MsoNormal style='margin-left:52.8pt;text-indent:-.25in;mso-list:l4 level1 lfo6;
2152 tab-stops:list 52.8pt'><![if !supportLists]><span style='mso-fareast-font-family:
2153 Arial;mso-bidi-font-family:Arial'><span style='mso-list:Ignore'>4.<span
2154 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><![endif]>You
2155 should configure Redboot so that the “Validate RAM address during load” option
2156 is not selected. This is set in the “Redboot ROM monitor” package, beneath
2157 “Build Redboot ROM ELF image”. This is the default setting if you use one of
2158 the Redboot configuration (.ecm) files provided with eCos for Nios II.</p>
2160 <p class=MsoNormal>Having configured your system to match these criteria, it is
2161 possible to download and execute HAL based applications using the “load” and
2162 “go” commands described in the Redboot documentation.<span
2163 style='mso-spacerun:yes'>    </span></p>
2165 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958837"></a><a
2166 name="_Toc120958809"><span style='mso-bookmark:_Toc120958837'><![if !supportLists]><span
2167 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2168 style='mso-list:Ignore'>11.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2169 </span></span></span><![endif]>Character device access</span></a></h1>
2171 <p class=MsoNormal>Devices drivers are supplied for three classes of Avalon
2172 character devices: <i style='mso-bidi-font-style:normal'>altera_avalon_jtag_uart</i>,
2173 <i style='mso-bidi-font-style:normal'>altera_avalon_uart</i>, and <i
2174 style='mso-bidi-font-style:normal'>altera_avalon_lcd_16207</i>. Devices of
2175 these types can be accessed using the standard eCos device access functions,
2176 e.g.: <i style='mso-bidi-font-style:normal'>open(), read(), write()</i> etc.
2177 The name of the device to use in the call to <i style='mso-bidi-font-style:
2178 normal'>open()</i> is the name assigned in SOPC builder with the prefix
2179 “/dev/”. For example, a device named “jtag_uart” in SOPC builder can be
2180 accessed as “/dev/jtag_uart” from eCos.</p>
2182 <p class=MsoNormal>The exceptions to this rule are those devices selected for
2183 the console and debug devices. The console device can instead be accessed as
2184 “/dev/haldiag”. </p>
2186 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958838"></a><a
2187 name="_Toc120958810"><span style='mso-bookmark:_Toc120958838'><![if !supportLists]><span
2188 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2189 style='mso-list:Ignore'>12.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2190 </span></span></span><![endif]>Compact Flash interface</span></a></h1>
2192 <p class=MsoNormal>This release of eCos includes a driver for the <i
2193 style='mso-bidi-font-style:normal'>altera_avalon_cf</i> compact flash component
2194 provided with the Nios II kit.</p>
2196 <p class=MsoNormal>You can create projects which give read/write access to a
2197 compact flash interface using the FAT file system by adding the following
2198 packages to your project: <i style='mso-bidi-font-style:normal'>FAT file system</i>
2199 (CYGPKG_FS_FAT); <i style='mso-bidi-font-style:normal'>Disk Device Drivers</i>
2200 (CYGPKG_IO_DISK); <i style='mso-bidi-font-style:normal'>File IO</i>
2201 (CYPKG_IO_FILEIO); <i style='mso-bidi-font-style:normal'>Block cache and access
2202 library</i> (CYPKG_BLOCK_LIB); and <i style='mso-bidi-font-style:normal'>Linux
2203 compatibility</i> (CYGPKG_LINUX_COMPAT). This package list assumes that you are
2204 using the default package template.</p>
2206 <p class=MsoNormal>You can add packages to a project by selecting
2207 Build-&gt;Packages… in <i style='mso-bidi-font-style:normal'>configtool</i>.</p>
2209 <p class=MsoNormal>Having added the packages, you should accept any suggested
2210 conflict resolutions.</p>
2212 <p class=MsoNormal>An example of how to read and write a FAT file system is
2213 given in the file, <i style='mso-bidi-font-style:normal'>fileio1.c</i>. This is
2214 located in the directory <i style='mso-bidi-font-style:normal'>ecos-current\packages\fs\fat\current\tests</i>
2215 beneath your eCos install. Note that this example assumes the device name
2216 &quot;/dev/disk0/1”. You will need to changes this to match the name of the
2217 device you have available in your project. Device naming is discussed in the
2218 next section.<span style='mso-spacerun:yes'>  </span></p>
2220 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958839"></a><a
2221 name="_Toc120958811"><span style='mso-bookmark:_Toc120958839'><![if !supportLists]><span
2222 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2223 style='mso-list:Ignore'>12.1<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2224 </span></span></span><![endif]>Compact Flash device name</span></a></h2>
2226 <p class=MsoNormal>For a given instance of the <i style='mso-bidi-font-style:
2227 normal'>altera_avalon_cf</i> component within an SOPC builder project, up to
2228 two disk drivers are available for use. These two drivers correspond to the two
2229 separate devices that can be managed by a single component interface.<span
2230 style='mso-spacerun:yes'>  </span></p>
2232 <p class=MsoNormal>The names given to these drivers are based on the name
2233 assigned to the component instance in SOPC builder. For example if the
2234 component instance is named “cf”, then the drivers will be named “/dev/cfa/”
2235 and “/dev/cfb/”. The suffix “a” and “b” indicate the first and second devices
2236 connected to the interface.<span style='mso-spacerun:yes'>  </span></p>
2238 <p class=MsoNormal>These device names can be used to give you direct IDE access
2239 to the device. However, it is more usual to access the device using the FAT
2240 file system. In this case, you will want to access a particular partition
2241 within the device. To do this you should append the partition number to the end
2242 of the device name. Partition number 1 is the first partition. Up to four
2243 partitions are supported.</p>
2245 <p class=MsoNormal>For example to mount a FAT file system on the first
2246 partition of the first device connected to a component instance named cf, you
2247 should make the following function call:</p>
2249 <p class=MsoNormal align=center style='text-align:center'><span
2250 style='font-family:"Courier New";mso-bidi-font-family:"Times New Roman"'>mount(
2251 &quot;/dev/cfa/1&quot;, &quot;/&quot;, &quot;fatfs&quot; );<span
2252 style='mso-spacerun:yes'>  </span><o:p></o:p></span></p>
2254 <p class=MsoNormal>Using partition zero gives you access to the root partition.
2255 This should be used if you wish to make raw IDE accesses to the device, or if
2256 the device has been formatted without a master boot record that would otherwise
2257 contain the partition table. Accessing device “/dev/cfa/0” is equivalent to
2258 using “/dev/cfa/”.</p>
2260 <h2 style='margin-left:0in;text-indent:0in'><a name="_Toc120958840"></a><a
2261 name="_Toc120958812"><span style='mso-bookmark:_Toc120958840'><![if !supportLists]><span
2262 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2263 style='mso-list:Ignore'>12.2<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2264 </span></span></span><![endif]>Inserting and removing Compact Flash cards</span></a></h2>
2266 <p class=MsoNormal>The <i style='mso-bidi-font-style:normal'>altera_avalon_cf</i>
2267 component provides an interrupt on card insert and removal. This is used to
2268 automatically update the available device list and partition tables when a card
2269 is inserted or removed.</p>
2271 <p class=MsoNormal>However it is important to ensure that you call the <i
2272 style='mso-bidi-font-style:normal'>umount()</i> function for any mounted file
2273 system on a card before ejecting it. If this is not done, then the file system
2274 may become corrupted and the operating system may become unstable.</p>
2276 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958841"></a><a
2277 name="_Toc120958813"><span style='mso-bookmark:_Toc120958841'><![if !supportLists]><span
2278 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2279 style='mso-list:Ignore'>13.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2280 </span></span></span><![endif]>Changing your hardware configuration</span></a></h1>
2282 <p class=MsoNormal>If you modify your SOPC builder system, then you must restart
2283 <i style='mso-bidi-font-style:normal'>nios2configtool</i> and re-build the eCos
2284 library for the changes to take effect. This will automatically update the
2285 available options and defaults to match your hardware configuration. However if
2286 you have previously changed any parameter away from its default setting, then
2287 you may need to update that parameter manually to match your new system
2288 configuration.</p>
2290 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958842"></a><a
2291 name="_Toc120958814"><span style='mso-bookmark:_Toc120958842'><![if !supportLists]><span
2292 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2293 style='mso-list:Ignore'>14.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2294 </span></span></span><![endif]>Configtool and the Nios II IDE</span></a></h1>
2296 <p class=MsoNormal>The standard version of <i style='mso-bidi-font-style:normal'>configtool</i>
2297 released with eCos creates additional mount points for its build environment.
2298 These mount points can lead to problems when using the Nios II IDE, even for
2299 applications which are not based on eCos. To avoid this, the version of <i
2300 style='mso-bidi-font-style:normal'>configtool</i> supplied here does not create
2301 these mount points. </p>
2303 <p class=MsoNormal>If you wish to use the original version of <i
2304 style='mso-bidi-font-style:normal'>configtool</i>, it is still available as a
2305 part of this release. It has been renamed as configtool20.exe.<span
2306 style='mso-spacerun:yes'>  </span></p>
2308 <h1 style='margin-left:0in;text-indent:0in'><a name="_Toc120958843"></a><a
2309 name="_Toc120958815"><span style='mso-bookmark:_Toc120958843'><![if !supportLists]><span
2310 style='mso-fareast-font-family:Arial;mso-bidi-font-family:Arial'><span
2311 style='mso-list:Ignore'>15.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;
2312 </span></span></span><![endif]>Limitations</span></a></h1>
2314 <ul style='margin-top:0in' type=disc>
2315 <li class=MsoNormal style='mso-list:l0 level1 lfo7;tab-stops:list .5in'>This
2316 port of eCos for Nios II only supports running on Windows hosts. </li>
2317 <li class=MsoNormal style='mso-list:l0 level1 lfo7;tab-stops:list .5in'>No
2318 exception handling is provided for the emulation of multiply and divide instructions
2319 when they are not supported in hardware. You should instead use the <i
2320 style='mso-bidi-font-style:normal'>--mno-hw-mul</i>, and <i
2321 style='mso-bidi-font-style:normal'>--mno-hw-div</i> compiler and linker
2322 flags. This is done automatically when using <i style='mso-bidi-font-style:
2323 normal'>nios2configtool</i>.</li>
2324 <li class=MsoNormal style='mso-list:l0 level1 lfo7;tab-stops:list .5in'>No
2325 support is provided for the Redboot system call interface. This means that
2326 GDB cannot be used to provide a host-based file system.</li>
2327 </ul>
2329 <p class=MsoNormal><o:p>&nbsp;</o:p></p>
2331 </div>
2333 </body>
2335 </html>